不知名提交
6
mengyanote-frontend/public/data/stats.json
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
{
|
||||||
|
"totalFiles": 246,
|
||||||
|
"totalFolders": 53,
|
||||||
|
"generatedAt": "2025-11-29T11:17:51.031Z",
|
||||||
|
"sourceDirectory": "E:\\React\\markdown-to-web\\public\\mengyanote"
|
||||||
|
}
|
||||||
|
Before Width: | Height: | Size: 1.2 MiB After Width: | Height: | Size: 1.2 MiB |
@@ -3,5 +3,6 @@
|
|||||||
"readableLineLength": false,
|
"readableLineLength": false,
|
||||||
"strictLineBreaks": false,
|
"strictLineBreaks": false,
|
||||||
"showLineNumber": false,
|
"showLineNumber": false,
|
||||||
"rightToLeft": false
|
"rightToLeft": false,
|
||||||
|
"spellcheck": false
|
||||||
}
|
}
|
||||||
10
mengyanote-frontend/public/mengyanote/.obsidian/appearance.json
vendored
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"cssTheme": "GitHub Theme",
|
||||||
|
"theme": "moonstone",
|
||||||
|
"monospaceFontFamily": "Maple Mono NF CN",
|
||||||
|
"baseFontSize": 18,
|
||||||
|
"interfaceFontFamily": "Maple Mono NF CN",
|
||||||
|
"textFontFamily": "霞鹜文楷,Maple Mono NF CN",
|
||||||
|
"nativeMenus": false,
|
||||||
|
"accentColor": "#fec834"
|
||||||
|
}
|
||||||
@@ -2,15 +2,15 @@
|
|||||||
"file-explorer": true,
|
"file-explorer": true,
|
||||||
"global-search": true,
|
"global-search": true,
|
||||||
"switcher": true,
|
"switcher": true,
|
||||||
"graph": true,
|
"graph": false,
|
||||||
"backlink": true,
|
"backlink": true,
|
||||||
"canvas": true,
|
"canvas": false,
|
||||||
"outgoing-link": true,
|
"outgoing-link": true,
|
||||||
"tag-pane": true,
|
"tag-pane": true,
|
||||||
"properties": false,
|
"properties": false,
|
||||||
"page-preview": true,
|
"page-preview": true,
|
||||||
"daily-notes": true,
|
"daily-notes": false,
|
||||||
"templates": true,
|
"templates": false,
|
||||||
"note-composer": true,
|
"note-composer": true,
|
||||||
"command-palette": true,
|
"command-palette": true,
|
||||||
"slash-command": false,
|
"slash-command": false,
|
||||||
@@ -19,15 +19,15 @@
|
|||||||
"markdown-importer": false,
|
"markdown-importer": false,
|
||||||
"zk-prefixer": false,
|
"zk-prefixer": false,
|
||||||
"random-note": false,
|
"random-note": false,
|
||||||
"outline": true,
|
"outline": false,
|
||||||
"word-count": true,
|
"word-count": true,
|
||||||
"slides": false,
|
"slides": false,
|
||||||
"audio-recorder": false,
|
"audio-recorder": false,
|
||||||
"workspaces": false,
|
"workspaces": false,
|
||||||
"file-recovery": true,
|
"file-recovery": true,
|
||||||
"publish": false,
|
"publish": false,
|
||||||
"sync": true,
|
"sync": false,
|
||||||
"webviewer": false,
|
"webviewer": false,
|
||||||
"footnotes": false,
|
"footnotes": false,
|
||||||
"bases": true
|
"bases": false
|
||||||
}
|
}
|
||||||
@@ -25,7 +25,7 @@
|
|||||||
"usePathObfuscation": false,
|
"usePathObfuscation": false,
|
||||||
"doNotDeleteFolder": false,
|
"doNotDeleteFolder": false,
|
||||||
"resolveConflictsByNewerFile": false,
|
"resolveConflictsByNewerFile": false,
|
||||||
"batchSave": false,
|
"batchSave": true,
|
||||||
"batchSaveMinimumDelay": 5,
|
"batchSaveMinimumDelay": 5,
|
||||||
"batchSaveMaximumDelay": 60,
|
"batchSaveMaximumDelay": 60,
|
||||||
"deviceAndVaultName": "",
|
"deviceAndVaultName": "",
|
||||||
@@ -68,7 +68,7 @@
|
|||||||
"syncAfterMerge": true,
|
"syncAfterMerge": true,
|
||||||
"configPassphraseStore": "",
|
"configPassphraseStore": "",
|
||||||
"encryptedPassphrase": "",
|
"encryptedPassphrase": "",
|
||||||
"encryptedCouchDBConnection": "%$Lm4s2DqCoARDdP/gXNSI+OA1xLmG7eftRPfa/sz+9NLvRqszRC6f1/bSP/JuvQukUqSMBTGq74zubYyEwq+/vd/MuXsJs2gNvmyTvsBfeV8y75WYXCV5zgg57lVGzWEPBiZ8dX9uXS4HyDmSjT+EPXRsVQn4uGecyPn52nQvHG8TJFz0lwMl0keTpJezd5HlnQAWPqFeVLxTdIoIOh2+uFA83Iyd6X5XsRxDapAwVdy0XATKjB+rUVQnLONWWg1UEJB/kKNlFnfprTrW7LFXXmUr8HueokoPzu/dcKbK0TyVu7EKTnNxGtkPUYCAk+vAxpCoGV/n5ApDaRo49VDMM22WamPbRH4+wZkd2ZAQVJn/5eqwR/3nAVVfm8ctbhaP1uXeDjPz0cpK0MSn2xVmjLKADdVpF/KBW2Vfe4SJnO6QEqOWa+pMRW38OAiv/iKZSAATBGFLv/iFuDYZye/bDf+SlaQQ+ZrqSVflo8Aj8cLPh1Okw3zeuK+4j7P1gJm82jZTZPSZvYBTaiyjeU5qBdGDJjuslrTYezCpWnkgXhdi/nSnw7iJoK5kAtvisZvSNlVDM+t82YjBdoZT9BxsVu1sisXXUzjcw8Ycx1gj4EtH1xiqEoyxiJEC0FASV4r+9Wrg4r+oQESSR9B2/Z0Lhd80WsEMDS1RGV6jJqDLPhvTD38ouRuTbkU4+Xsr9T4mabU1KvQdYpE=",
|
"encryptedCouchDBConnection": "%$Bh465+EFQMTElwFFSDGASKI1SLpAExbeorlbZRkteweG3W2aZo9y25x4kbHgwa+9MNvE7ALlSWzLpSh7vriIQ8CZBeJeOgrv8b2DWVhDFOo42t0hScnVRlzhmaXERAzgvlBmMW9DxhV3oNPFDM3Q2leCEpAVGRhOhVJrp68emgdQOYQ5xVRWVAAwxvp/sWL1O6nerkxFH2hvA+AUPp05alJ9tycmVWPUKwclnoDknBfW5k9Ft90nPpcX9EgAO6IRMlp8X5bD0a26g1ti0ImFiA7Qi/1kl+Ymi7rDtzQEODtqhs5BPDHf/7oTU/MBWywlRiNOw22341Fvi+EvJb4QqZPFLUfwlrXCq81CTCrhV59kcl+s+IrWr8Wroo/cbbifyLjQ9IDYCeUHwe4lbWI0fGgjUJUAbWiRDAU8stifNwHON/PNyFd2/FR+e8PETbmWMxH7vuHjEPs8INUEvKiMOVZ7k0jwWM5xro8zGCYOYVmd5pInOXmHjypr3StPtXvgS2eOizsPZRrMsKlJ8gkcgHK32gOcBGwWVZ2iUkaP9vl6DztLB/uf2zgjTnlNk8MCtE4SAXSag1ipu/V6LVTzGmAkZT0VdG9TxzvDIaNHWhvvk1PekzagIU08xiAyh2Tin+hP6YJEujJ7S9jOn1//PuayuGFeD0KExmj7jxnrVvgN4QtrtO0b8/EqRni5qtzRVRslDpqhFuw=",
|
||||||
"permitEmptyPassphrase": false,
|
"permitEmptyPassphrase": false,
|
||||||
"useIndexedDBAdapter": true,
|
"useIndexedDBAdapter": true,
|
||||||
"useTimeouts": false,
|
"useTimeouts": false,
|
||||||
40
mengyanote-frontend/public/mengyanote/.obsidian/plugins/obsidian-style-settings/data.json
vendored
Normal file
@@ -0,0 +1,40 @@
|
|||||||
|
{
|
||||||
|
"Components@@CTA-BTN-enable": true,
|
||||||
|
"Components@@file-names-untrim": true,
|
||||||
|
"Components@@folder-font-bold": true,
|
||||||
|
"Components@@colorful-folder": true,
|
||||||
|
"Components@@file-icon-remove": false,
|
||||||
|
"Components@@outline-enhanced": true,
|
||||||
|
"Components@@new-tab-btn-select": "new-tab-btn-default",
|
||||||
|
"Components@@immersive-canvas": true,
|
||||||
|
"Components@@scrollbar-hide": true,
|
||||||
|
"Mobile@@drawer-phone-full-width": true,
|
||||||
|
"Mobile@@card-layout-pad-open": true,
|
||||||
|
"Plugin@@colorful-checkbox": true,
|
||||||
|
"Editor@@italic-color@@light": "#000000",
|
||||||
|
"Editor@@text-highlight-bg@@light": "#000000",
|
||||||
|
"Editor@@inline-code-normal@@light": "#000000",
|
||||||
|
"Editor@@link-color@@light": "#000000",
|
||||||
|
"Editor@@link-color-hover@@light": "#000000",
|
||||||
|
"Editor@@h1-weight": 900,
|
||||||
|
"Editor@@h2-weight": 850,
|
||||||
|
"Editor@@h3-weight": 800,
|
||||||
|
"Editor@@h4-weight": 750,
|
||||||
|
"Editor@@h5-weight": 700,
|
||||||
|
"Editor@@h6-weight": 650,
|
||||||
|
"Editor@@h6-divider-on": false,
|
||||||
|
"Editor@@h5-divider-on": false,
|
||||||
|
"Editor@@h4-divider-on": false,
|
||||||
|
"Editor@@h3-divider-on": false,
|
||||||
|
"Editor@@h2-divider-on": false,
|
||||||
|
"Editor@@h1-divider-on": false,
|
||||||
|
"Editor@@collapse-icon-restore": false,
|
||||||
|
"Editor@@inline-title-divider-remove": true,
|
||||||
|
"Editor@@text-align-justify": false,
|
||||||
|
"Editor@@bold-color@@dark": "#000000",
|
||||||
|
"Editor@@bold-color@@light": "#000000",
|
||||||
|
"Editor@@editor-grid-background-pattren": true,
|
||||||
|
"Editor@@border-focus-mode": false,
|
||||||
|
"Editor@@line-hover-indicator": true,
|
||||||
|
"Appearance-light@@card-layout-open-light": true
|
||||||
|
}
|
||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "Border",
|
"name": "Border",
|
||||||
"version": "1.12.11",
|
"version": "1.12.20",
|
||||||
"minAppVersion": "0.16.0",
|
"minAppVersion": "0.16.0",
|
||||||
"author": "Akifyss",
|
"author": "Akifyss",
|
||||||
"authorUrl": "https://github.com/Akifyss"
|
"authorUrl": "https://github.com/Akifyss"
|
||||||
@@ -369,7 +369,7 @@ settings:
|
|||||||
type: variable-color
|
type: variable-color
|
||||||
format: hsl-split
|
format: hsl-split
|
||||||
opacity: false
|
opacity: false
|
||||||
default: '#3751fb'
|
default: '#4b63fb'
|
||||||
-
|
-
|
||||||
id: accent-color-override-light
|
id: accent-color-override-light
|
||||||
title: Override accent color setting in "Settings-Appearance" menu(light mode)
|
title: Override accent color setting in "Settings-Appearance" menu(light mode)
|
||||||
@@ -3872,7 +3872,7 @@ body {
|
|||||||
/* Accent HSL values */
|
/* Accent HSL values */
|
||||||
--accent-h: 232;
|
--accent-h: 232;
|
||||||
--accent-s: 96%;
|
--accent-s: 96%;
|
||||||
--accent-l: 60%;
|
--accent-l: 64%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.theme-light.accent-color-override-light {
|
.theme-light.accent-color-override-light {
|
||||||
@@ -3931,7 +3931,7 @@ body {
|
|||||||
--accent-l: var(--accent-light-l);
|
--accent-l: var(--accent-light-l);
|
||||||
--accent-light-h: 232;
|
--accent-light-h: 232;
|
||||||
--accent-light-s: 96%;
|
--accent-light-s: 96%;
|
||||||
--accent-light-l: 60%;
|
--accent-light-l: 64%;
|
||||||
--color-accent-hsl: var(--color-accent-hsl-light);
|
--color-accent-hsl: var(--color-accent-hsl-light);
|
||||||
--color-accent: var(--color-accent-light);
|
--color-accent: var(--color-accent-light);
|
||||||
--color-accent-1: var(--color-accent-1-light);
|
--color-accent-1: var(--color-accent-1-light);
|
||||||
@@ -3944,6 +3944,7 @@ body {
|
|||||||
--color-accent-1-light: hsl(calc(var(--accent-h) - 1), calc(var(--accent-s) * 1.01), calc(var(--accent-l) * 1.075));
|
--color-accent-1-light: hsl(calc(var(--accent-h) - 1), calc(var(--accent-s) * 1.01), calc(var(--accent-l) * 1.075));
|
||||||
--color-accent-2-light: hsl(calc(var(--accent-h) - 3), calc(var(--accent-s) * 1.02), calc(var(--accent-l) * 1.15));
|
--color-accent-2-light: hsl(calc(var(--accent-h) - 3), calc(var(--accent-s) * 1.02), calc(var(--accent-l) * 1.15));
|
||||||
--color-accent-3-light: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)));
|
--color-accent-3-light: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)));
|
||||||
|
--background-modifier-border-muted: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.1);
|
||||||
--background-modifier-border: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.2);
|
--background-modifier-border: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.2);
|
||||||
--background-modifier-border-hover: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.25);
|
--background-modifier-border-hover: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.25);
|
||||||
--background-modifier-border-focus: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.3);
|
--background-modifier-border-focus: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(var(--accent-l)), 0.3);
|
||||||
@@ -3954,8 +3955,8 @@ body {
|
|||||||
calc(100% - (100% - var(--accent-l)) / 16));
|
calc(100% - (100% - var(--accent-l)) / 16));
|
||||||
--background-secondary-alt: var(--color-base-05);
|
--background-secondary-alt: var(--color-base-05);
|
||||||
--background-tertiary: hsl(var(--accent-h),
|
--background-tertiary: hsl(var(--accent-h),
|
||||||
calc((var(--accent-s)) / 2),
|
calc((var(--accent-s)) / 1.5),
|
||||||
calc(100% - (100% - var(--accent-l)) / 12));
|
calc(100% - (100% - var(--accent-l)) / 10));
|
||||||
--workspace-background-translucent: rgba(246, 246, 246, 0.8);
|
--workspace-background-translucent: rgba(246, 246, 246, 0.8);
|
||||||
--background-modifier-hover: hsla(var(--accent-h), 6%, 64%, 0.15);
|
--background-modifier-hover: hsla(var(--accent-h), 6%, 64%, 0.15);
|
||||||
--background-modifier-active-hover: hsla(var(--interactive-accent-hsl), 0.15);
|
--background-modifier-active-hover: hsla(var(--interactive-accent-hsl), 0.15);
|
||||||
@@ -4063,6 +4064,7 @@ body {
|
|||||||
--color-accent-1-dark: hsl(calc(var(--accent-h) - 3), calc(var(--accent-s) * 1.02), calc(var(--accent-l) * 1.15));
|
--color-accent-1-dark: hsl(calc(var(--accent-h) - 3), calc(var(--accent-s) * 1.02), calc(var(--accent-l) * 1.15));
|
||||||
--color-accent-2-dark: hsl(calc(var(--accent-h) - 5), calc(var(--accent-s) * 1.05), calc(var(--accent-l) * 1.29));
|
--color-accent-2-dark: hsl(calc(var(--accent-h) - 5), calc(var(--accent-s) * 1.05), calc(var(--accent-l) * 1.29));
|
||||||
--color-accent-3-dark: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)));
|
--color-accent-3-dark: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)));
|
||||||
|
--background-modifier-border-muted: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.1);
|
||||||
--background-modifier-border: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.2);
|
--background-modifier-border: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.2);
|
||||||
--background-modifier-border-hover: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.25);
|
--background-modifier-border-hover: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.25);
|
||||||
--background-modifier-border-focus: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.3);
|
--background-modifier-border-focus: hsla(var(--accent-h), calc(0.4*var(--accent-s)), calc(0.9*var(--accent-l)), 0.3);
|
||||||
@@ -4643,7 +4645,7 @@ body:not(.is-mobile).theme-dark:not(.card-layout-open-dark).mod-root-split-backg
|
|||||||
/* ====== Layout ===== */
|
/* ====== Layout ===== */
|
||||||
/* default Layout*/
|
/* default Layout*/
|
||||||
body {
|
body {
|
||||||
--card-shadow-light: 0 -1px 0 0 rgba(255, 255, 255, .24), 0 0 0 1px var(--background-modifier-border), 0 0 6px var(--background-modifier-border);
|
--card-shadow-light: 0 0 0 1px var(--background-modifier-border-muted), 0 0 6px var(--background-modifier-border-muted);
|
||||||
--card-shadow-dark: 0 -1px 0 0 var(--background-modifier-border), 0 0 0 1px var(--background-modifier-border);
|
--card-shadow-dark: 0 -1px 0 0 var(--background-modifier-border), 0 0 0 1px var(--background-modifier-border);
|
||||||
--card-border-radius-light: 8px;
|
--card-border-radius-light: 8px;
|
||||||
--card-border-radius-dark: 8px;
|
--card-border-radius-dark: 8px;
|
||||||
@@ -4982,15 +4984,19 @@ body:not(.is-translucent) .titlebar-text {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.titlebar-button-container.mod-right .titlebar-button.mod-close::after {
|
.titlebar-button-container.mod-right .titlebar-button.mod-close::after {
|
||||||
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cg clip-path='url(%23a)'%3e%3cpath stroke='black' stroke-width='2' d='m3.757 12.243 8.486-8.486m0 8.486L3.757 3.757'/%3e%3c/g%3e%3cdefs%3e%3cclipPath id='a'%3e%3cpath fill='white' d='M0 0h8v8H0z' transform='translate(4 4)'/%3e%3c/clipPath%3e%3c/defs%3e%3c/svg%3e");
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-linecap='round' stroke-width='1.5' d='m4.464 11.535 7.071-7.07m.001 7.071L4.464 4.464'/%3e%3c/svg%3e");
|
||||||
}
|
}
|
||||||
|
|
||||||
.titlebar-button-container.mod-right .titlebar-button.mod-maximize::after {
|
body:not(.is-maximized) .titlebar-button-container.mod-right .titlebar-button.mod-maximize::after {
|
||||||
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-width='2' d='M5 5h6v6H5z'/%3e%3c/svg%3e");
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3crect width='8' height='8' x='4' y='4' stroke='black' stroke-width='1.5' rx='2'/%3e%3c/svg%3e");
|
||||||
|
}
|
||||||
|
|
||||||
|
.is-maximized .titlebar-button-container.mod-right .titlebar-button.mod-maximize::after {
|
||||||
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cg stroke='black' stroke-width='1.5'%3e%3crect width='7' height='7' x='3' y='6' rx='2'/%3e%3cpath d='M9.5 10H11a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2H8a2 2 0 0 0-2 2v1.5'/%3e%3c/g%3e%3c/svg%3e");
|
||||||
}
|
}
|
||||||
|
|
||||||
.titlebar-button-container.mod-right .titlebar-button.mod-minimize::after {
|
.titlebar-button-container.mod-right .titlebar-button.mod-minimize::after {
|
||||||
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-width='2' d='M4 11h8'/%3e%3c/svg%3e");
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-linecap='round' stroke-width='1.5' d='M3.5 8h9'/%3e%3c/svg%3e");
|
||||||
}
|
}
|
||||||
|
|
||||||
@media (hover: hover) {
|
@media (hover: hover) {
|
||||||
@@ -5138,9 +5144,9 @@ body {
|
|||||||
--color-activated-tab-header-light: var(--text-normal);
|
--color-activated-tab-header-light: var(--text-normal);
|
||||||
--color-activated-tab-header-dark: var(--text-normal);
|
--color-activated-tab-header-dark: var(--text-normal);
|
||||||
--background-activated-tab-header-light: var(--background-primary);
|
--background-activated-tab-header-light: var(--background-primary);
|
||||||
--shadow-activated-tab-header-light: 0 -1px 0 0 rgba(255, 255, 255, .24), 0 0 0 1px var(--background-modifier-border), 0 0 6px var(--background-modifier-border), 0px 4px 8px -6px var(--background-modifier-border), inset 0px -1px 0px var(--background-tertiary), inset 0 -2px 2px 0 var(--background-tertiary);
|
--shadow-activated-tab-header-light: 0 -1px 0 0 rgba(255, 255, 255, .24), 0 0 0 1px var(--background-modifier-border), 0 0 4px var(--background-modifier-border), 0px 2px 6px -4px var(--background-modifier-border-muted), inset 0px -1px 0px var(--background-tertiary), inset 0 -2px 4px 0 var(--background-tertiary);
|
||||||
--background-activated-tab-header-dark: var(--background-modifier-active-hover);
|
--background-activated-tab-header-dark: var(--background-modifier-active-hover);
|
||||||
--shadow-activated-tab-header-dark: inset 0 0 0 1px var(--background-modifier-border), inset 0 2px 4px 0 var(--background-modifier-border), inset 0 1px 1px 1px var(--background-modifier-border);
|
--shadow-activated-tab-header-dark: inset 0 0 0 1px var(--background-modifier-border), inset 0 2px 4px 0 var(--background-modifier-border-muted), inset 0 1px 1px 1px var(--background-modifier-border);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -6445,6 +6451,10 @@ body:not(.file-icon-remove) .workspace-leaf-content[data-type="file-explorer"] .
|
|||||||
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.333' d='M6 2H2.667A.667.667 0 0 0 2 2.667v4.666c0 .369.298.667.667.667H6a.667.667 0 0 0 .667-.667V2.667A.667.667 0 0 0 6 2Zm7.333 0H10a.667.667 0 0 0-.667.667v2c0 .368.299.666.667.666h3.333A.667.667 0 0 0 14 4.667v-2A.667.667 0 0 0 13.333 2Zm0 6H10a.667.667 0 0 0-.667.667v4.666c0 .368.299.667.667.667h3.333a.667.667 0 0 0 .667-.667V8.667A.667.667 0 0 0 13.333 8ZM6 10.667H2.667a.667.667 0 0 0-.667.666v2c0 .368.298.667.667.667H6a.667.667 0 0 0 .667-.667v-2A.667.667 0 0 0 6 10.667Z'/%3e%3c/svg%3e");
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.333' d='M6 2H2.667A.667.667 0 0 0 2 2.667v4.666c0 .369.298.667.667.667H6a.667.667 0 0 0 .667-.667V2.667A.667.667 0 0 0 6 2Zm7.333 0H10a.667.667 0 0 0-.667.667v2c0 .368.299.666.667.666h3.333A.667.667 0 0 0 14 4.667v-2A.667.667 0 0 0 13.333 2Zm0 6H10a.667.667 0 0 0-.667.667v4.666c0 .368.299.667.667.667h3.333a.667.667 0 0 0 .667-.667V8.667A.667.667 0 0 0 13.333 8ZM6 10.667H2.667a.667.667 0 0 0-.667.666v2c0 .368.298.667.667.667H6a.667.667 0 0 0 .667-.667v-2A.667.667 0 0 0 6 10.667Z'/%3e%3c/svg%3e");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
body:not(.file-icon-remove) .workspace-leaf-content[data-type="file-explorer"] .nav-file-title[data-path$=".base"]::before {
|
||||||
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cpath stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.333' d='M6 2H2.667A.667.667 0 0 0 2 2.667V6c0 .368.298.667.667.667H6A.667.667 0 0 0 6.667 6V2.667A.667.667 0 0 0 6 2Zm0 7.333H2.667A.667.667 0 0 0 2 10v3.333c0 .368.298.667.667.667H6a.667.667 0 0 0 .667-.667V10A.667.667 0 0 0 6 9.333Zm3.333-6.666H14M9.333 6H14m-4.667 4H14m-4.667 3.333H14'/%3e%3c/svg%3e");
|
||||||
|
}
|
||||||
|
|
||||||
body:not(.file-icon-remove) .workspace-leaf-content[data-type="file-explorer"] .is-unsupported.nav-file-title::before {
|
body:not(.file-icon-remove) .workspace-leaf-content[data-type="file-explorer"] .is-unsupported.nav-file-title::before {
|
||||||
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cg stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.333'%3e%3cpath d='M9.667 1.333H4a1.333 1.333 0 0 0-1.333 1.334v10.666A1.333 1.333 0 0 0 4 14.667h8a1.333 1.333 0 0 0 1.333-1.334V5L9.667 1.333Z'/%3e%3cpath d='M6.667 6.867c.133-.267.333-.534.6-.667A1.4 1.4 0 0 1 9 6.467c.2.266.333.533.333.866C9.333 8.2 8 8.667 8 8.667m0 2.666h.007'/%3e%3c/g%3e%3c/svg%3e");
|
-webkit-mask-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='none' viewBox='0 0 16 16'%3e%3cg stroke='black' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.333'%3e%3cpath d='M9.667 1.333H4a1.333 1.333 0 0 0-1.333 1.334v10.666A1.333 1.333 0 0 0 4 14.667h8a1.333 1.333 0 0 0 1.333-1.334V5L9.667 1.333Z'/%3e%3cpath d='M6.667 6.867c.133-.267.333-.534.6-.667A1.4 1.4 0 0 1 9 6.467c.2.266.333.533.333.866C9.333 8.2 8 8.667 8 8.667m0 2.666h.007'/%3e%3c/g%3e%3c/svg%3e");
|
||||||
}
|
}
|
||||||
@@ -6787,6 +6797,12 @@ body:not(.is-phone) div:has(>input.prompt-input) {
|
|||||||
--background-modifier-form-field: transparent;
|
--background-modifier-form-field: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.combobox .search-input-container input[type=search] {
|
||||||
|
border: 0 !important;
|
||||||
|
box-shadow: none !important;
|
||||||
|
background-color: transparent !important;
|
||||||
|
}
|
||||||
|
|
||||||
/* dropdown */
|
/* dropdown */
|
||||||
|
|
||||||
select,
|
select,
|
||||||
@@ -6867,6 +6883,10 @@ input.prompt-input {
|
|||||||
background-color: transparent !important;
|
background-color: transparent !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.base-toolbar-sort-item {
|
||||||
|
background-color: transparent;
|
||||||
|
}
|
||||||
|
|
||||||
/* notice */
|
/* notice */
|
||||||
.notice-container {
|
.notice-container {
|
||||||
top: 34px;
|
top: 34px;
|
||||||
@@ -7638,7 +7658,7 @@ body {
|
|||||||
--line-normal-opacity: 0.5;
|
--line-normal-opacity: 0.5;
|
||||||
}
|
}
|
||||||
|
|
||||||
.border-focus-mode .cm-lineWrapping>.cm-line.cm-active:not(:has(.mk-note-footer, .mk-floweditor-container)) {
|
.border-focus-mode .cm-lineWrapping>.cm-line.cm-active {
|
||||||
background-color: var(--line-active-bg);
|
background-color: var(--line-active-bg);
|
||||||
border-radius: var(--radius-s);
|
border-radius: var(--radius-s);
|
||||||
opacity: 1;
|
opacity: 1;
|
||||||
@@ -7675,17 +7695,10 @@ body {
|
|||||||
|
|
||||||
/*general*/
|
/*general*/
|
||||||
|
|
||||||
.line-hover-indicator .workspace-leaf-content:is([data-type="markdown"], [data-type="webviewer"]):not(:has(.document-search-container)) .markdown-preview-sizer>div:not(:has(.collapse-indicator, .mk-header)) {
|
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div::after {
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div:not(:has(.mk-note-footer)):has(.cm-hmd-list-indent)::after,
|
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div:not(.image-embed, .mk-header, .HyperMD-header, :has(.mk-note-footer, .collapse-indicator))::after,
|
|
||||||
.line-hover-indicator .workspace-leaf-content:is([data-type="markdown"], [data-type="webviewer"]):not(:has(.document-search-container)) .markdown-preview-sizer>div:is(.el-ul, .el-ol)::after,
|
|
||||||
.line-hover-indicator .workspace-leaf-content:is([data-type="markdown"], [data-type="webviewer"]):not(:has(.document-search-container)) .markdown-preview-sizer>div:not(:has(.collapse-indicator, .mk-header))::after {
|
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -12px;
|
left: -24px;
|
||||||
top: 3px;
|
top: 3px;
|
||||||
width: 3px;
|
width: 3px;
|
||||||
height: 0;
|
height: 0;
|
||||||
@@ -7695,21 +7708,22 @@ body {
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div:not(:has(.mk-note-footer)):has(.cm-hmd-list-indent):hover::after,
|
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>.HyperMD-quote::after {
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div:not(.image-embed, .mk-header, .HyperMD-header, :has(.mk-note-footer, .collapse-indicator)):hover::after,
|
left: calc(-24px - var(--blockquote-padding));
|
||||||
.line-hover-indicator .workspace-leaf-content:is([data-type="markdown"], [data-type="webviewer"]):not(:has(.document-search-container)) .markdown-preview-sizer>div:is(.el-ul, .el-ol):hover::after,
|
}
|
||||||
.line-hover-indicator .workspace-leaf-content:is([data-type="markdown"], [data-type="webviewer"]):not(:has(.document-search-container)) .markdown-preview-sizer>div:not(:has(.collapse-indicator, .mk-header)):hover::after {
|
|
||||||
|
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>div:hover::after {
|
||||||
height: calc(100% - 6px);
|
height: calc(100% - 6px);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* num */
|
/* num */
|
||||||
|
|
||||||
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:not(.HyperMD-list-line-1):after,
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:after,
|
||||||
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end)::after {
|
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end)::after {
|
||||||
background: unset !important;
|
background: unset !important;
|
||||||
opacity: 0 !important;
|
opacity: 0 !important;
|
||||||
position: absolute !important;
|
position: absolute !important;
|
||||||
left: -12px !important;
|
left: -24px !important;
|
||||||
top: 0px !important;
|
top: 0px !important;
|
||||||
height: 100% !important;
|
height: 100% !important;
|
||||||
width: 3px !important;
|
width: 3px !important;
|
||||||
@@ -7720,7 +7734,7 @@ body {
|
|||||||
color: var(--hover-indicator-color);
|
color: var(--hover-indicator-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:not(.HyperMD-list-line-1):hover::after,
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:hover::after,
|
||||||
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end):hover:after {
|
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end):hover:after {
|
||||||
opacity: 1 !important;
|
opacity: 1 !important;
|
||||||
--hover-indicator-color: var(--text-faint);
|
--hover-indicator-color: var(--text-faint);
|
||||||
@@ -7738,11 +7752,15 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* list */
|
/* list */
|
||||||
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:not(.HyperMD-list-line-1):after {
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line:after {
|
||||||
content: "";
|
content: "";
|
||||||
text-indent: 0px !important;
|
text-indent: 0px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line.HyperMD-list-line-1::after {
|
||||||
|
content: "1" !important;
|
||||||
|
}
|
||||||
|
|
||||||
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line.HyperMD-list-line-2::after {
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-line.HyperMD-list-line.HyperMD-list-line-2::after {
|
||||||
content: "2" !important;
|
content: "2" !important;
|
||||||
}
|
}
|
||||||
@@ -7781,11 +7799,10 @@ body {
|
|||||||
|
|
||||||
/* active line */
|
/* active line */
|
||||||
|
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>.cm-active:not(:has(.mk-note-footer)):has(.cm-hmd-list-indent)::after,
|
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>.cm-active::after {
|
||||||
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>.cm-active:not(.image-embed, .mk-header, .HyperMD-header, :has(.mk-note-footer, .collapse-indicator))::after {
|
|
||||||
content: "";
|
content: "";
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: -12px;
|
left: -24px;
|
||||||
top: 3px;
|
top: 3px;
|
||||||
width: 3px;
|
width: 3px;
|
||||||
height: calc(100% - 6px);
|
height: calc(100% - 6px);
|
||||||
@@ -7795,7 +7812,11 @@ body {
|
|||||||
opacity: 1;
|
opacity: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-active.HyperMD-list-line:not(.HyperMD-list-line-1)::after,
|
.line-hover-indicator .workspace-leaf-content[data-type="markdown"] .markdown-source-view .cm-content>.cm-active.HyperMD-quote::after {
|
||||||
|
left: calc(-24px - var(--blockquote-padding));
|
||||||
|
}
|
||||||
|
|
||||||
|
.line-hover-indicator.focus-indicator-list-level .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-active.HyperMD-list-line::after,
|
||||||
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-active.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end):after {
|
.line-hover-indicator.focus-indicator-codeblock-line-number .workspace-leaf-content[data-type="markdown"] .cm-contentContainer .cm-active.HyperMD-codeblock:not(.HyperMD-codeblock-begin):not(.HyperMD-codeblock-end):after {
|
||||||
opacity: 1 !important;
|
opacity: 1 !important;
|
||||||
--hover-indicator-color: var(--color-accent) !important;
|
--hover-indicator-color: var(--color-accent) !important;
|
||||||
@@ -8338,6 +8359,7 @@ body {
|
|||||||
--blockquote-background-color: transparent;
|
--blockquote-background-color: transparent;
|
||||||
--blockquote-background-light: var(--background-alt-light);
|
--blockquote-background-light: var(--background-alt-light);
|
||||||
--blockquote-background-dark: var(--background-alt-dark);
|
--blockquote-background-dark: var(--background-alt-dark);
|
||||||
|
--blockquote-padding: 8px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.theme-light .markdown-source-view .cm-scroller .cm-line.HyperMD-quote,
|
.theme-light .markdown-source-view .cm-scroller .cm-line.HyperMD-quote,
|
||||||
@@ -8352,87 +8374,71 @@ body {
|
|||||||
background: var(--blockquote-background-dark);
|
background: var(--blockquote-background-dark);
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-rendered blockquote,
|
|
||||||
.markdown-preview-view blockquote {
|
|
||||||
position: relative;
|
|
||||||
}
|
|
||||||
|
|
||||||
.markdown-rendered blockquote::before,
|
|
||||||
.markdown-preview-view blockquote::before {
|
|
||||||
content: "";
|
|
||||||
position: absolute;
|
|
||||||
left: 4px;
|
|
||||||
top: 4px;
|
|
||||||
height: calc(100% - 8px);
|
|
||||||
width: var(--blockquote-border-thickness);
|
|
||||||
background-color: var(--blockquote-border-color);
|
|
||||||
border-radius: 24px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.markdown-rendered blockquote {
|
.markdown-rendered blockquote {
|
||||||
border-left: none;
|
position: relative;
|
||||||
|
border-radius: var(--radius-s);
|
||||||
|
border-inline-start: none;
|
||||||
|
padding-inline: calc(16px + var(--blockquote-border-thickness) + var(--blockquote-padding)) var(--blockquote-padding);
|
||||||
|
padding-block: var(--blockquote-padding);
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6.is-live-preview .HyperMD-quote::before {
|
.markdown-rendered blockquote>blockquote {
|
||||||
content: "";
|
padding-inline-start: calc(16px + var(--blockquote-border-thickness));
|
||||||
width: var(--blockquote-border-thickness) !important;
|
padding-block: 0 !important;
|
||||||
border-left: none !important;
|
}
|
||||||
background-color: var(--blockquote-border-color);
|
|
||||||
border-radius: 24px;
|
.markdown-rendered blockquote>blockquote::before {
|
||||||
border-top-left-radius: 0px;
|
top: 0;
|
||||||
border-top-right-radius: 0px;
|
bottom: 0;
|
||||||
color: transparent;
|
inset-inline-start: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.markdown-rendered blockquote::before {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
left: 0px !important;
|
top: var(--blockquote-padding);
|
||||||
bottom: 4px !important;
|
bottom: var(--blockquote-padding);
|
||||||
height: calc(100% - 4px);
|
inset-inline-start: var(--blockquote-padding);
|
||||||
|
border-radius: var(--radius-s);
|
||||||
|
background-color: var(--blockquote-border-color);
|
||||||
|
width: var(--blockquote-border-thickness);
|
||||||
|
pointer-events: none;
|
||||||
|
content: "";
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6.is-live-preview .HyperMD-quote.cm-line {
|
.HyperMD-quote {
|
||||||
border-left: 4px solid transparent;
|
border: solid transparent;
|
||||||
|
border-width: 0 var(--blockquote-padding) 0 var(--blockquote-padding);
|
||||||
|
background-color: var(--blockquote-background-color);
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6 div:not(.HyperMD-quote)+.HyperMD-quote::before,
|
.HyperMD-quote::before {
|
||||||
.markdown-source-view.mod-cm6 .cm-content :first-child:is(.HyperMD-quote)::before {
|
width: 0 !important;
|
||||||
top: 4px !important;
|
|
||||||
height: calc(100% - 4px);
|
|
||||||
border-radius: 24px;
|
|
||||||
border-bottom-left-radius: 0px;
|
|
||||||
border-bottom-right-radius: 0px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6 div:not(.HyperMD-quote)+.HyperMD-quote:not(:has(+ .HyperMD-quote))::before,
|
.HyperMD-quote:first-child,
|
||||||
.markdown-source-view.mod-cm6 .cm-content :first-child:is(.HyperMD-quote):not(:has(+ .HyperMD-quote))::before {
|
.cm-sizer>div>div>*:not(.HyperMD-quote)+.HyperMD-quote {
|
||||||
bottom: 4px !important;
|
border-top-width: var(--blockquote-padding);
|
||||||
top: 4px !important;
|
border-start-start-radius: var(--radius-s);
|
||||||
height: calc(100% - 8px);
|
border-start-end-radius: var(--radius-s);
|
||||||
border-radius: 24px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6 .HyperMD-quote:has(+ .HyperMD-quote)::before {
|
.HyperMD-quote:first-child::before,
|
||||||
bottom: 0px !important;
|
.cm-sizer>div>div>*:not(.HyperMD-quote)+.HyperMD-quote::before {
|
||||||
height: 100%;
|
border-start-start-radius: var(--radius-s);
|
||||||
border-radius: 0px;
|
border-start-end-radius: var(--radius-s);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*---*/
|
.HyperMD-quote:last-child,
|
||||||
|
.cm-sizer>div>div>.HyperMD-quote:has(+ *:not(.HyperMD-quote)) {
|
||||||
.markdown-source-view.mod-cm6 .HyperMD-quote {
|
border-bottom-width: var(--blockquote-padding);
|
||||||
border-top-left-radius: 0 !important;
|
border-end-start-radius: var(--radius-s);
|
||||||
border-top-right-radius: 0 !important;
|
border-end-end-radius: var(--radius-s);
|
||||||
border-bottom-left-radius: var(--radius-s) !important;
|
|
||||||
border-bottom-right-radius: var(--radius-s) !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6 div:not(.HyperMD-quote)+.HyperMD-quote,
|
.HyperMD-quote:last-child::before,
|
||||||
.markdown-source-view.mod-cm6 .cm-content :first-child:is(.HyperMD-quote) {
|
.cm-sizer>div>div>.HyperMD-quote:has(+ *:not(.HyperMD-quote))::before {
|
||||||
border-top-left-radius: var(--radius-s) !important;
|
border-end-start-radius: var(--radius-s);
|
||||||
border-top-right-radius: var(--radius-s) !important;
|
border-end-end-radius: var(--radius-s);
|
||||||
}
|
|
||||||
|
|
||||||
.markdown-source-view.mod-cm6 .HyperMD-quote:has(+ .HyperMD-quote) {
|
|
||||||
border-bottom-left-radius: 0 !important;
|
|
||||||
border-bottom-right-radius: 0 !important;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/*kbd*/
|
/*kbd*/
|
||||||
@@ -8685,7 +8691,7 @@ body {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/* image hover effect */
|
/* image hover effect */
|
||||||
.markdown-source-view.mod-cm6 .cm-content>.internal-embed {
|
.markdown-source-view.mod-cm6 .cm-content>.image-embed {
|
||||||
contain: unset !important;
|
contain: unset !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -8804,15 +8810,6 @@ body {
|
|||||||
padding-top: 6px;
|
padding-top: 6px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.theme-light .clickable-icon.is-active {
|
|
||||||
background: linear-gradient(hsla(var(--interactive-accent-hsl), 0.05) 0%, hsla(var(--interactive-accent-hsl), 0.2) 100%);
|
|
||||||
box-shadow: inset 0 0 1px 1px hsla(0, 100%, 100%, 0.5), 0 0 0 1px var(--background-modifier-active-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
.theme-dark .clickable-icon.is-active {
|
|
||||||
box-shadow: inset 0 0 0 1px var(--background-modifier-active-hover), inset 0 2px 4px 0 var(--background-modifier-active-hover), inset 0 1px 1px 1px var(--background-modifier-active-hover);
|
|
||||||
}
|
|
||||||
|
|
||||||
.clickable-icon.document-search-button,
|
.clickable-icon.document-search-button,
|
||||||
.clickable-icon.document-search-close-button,
|
.clickable-icon.document-search-close-button,
|
||||||
body:not(.is-mobile) .workspace-split.mod-left-split .workspace-sidedock-vault-profile .workspace-drawer-vault-actions .clickable-icon,
|
body:not(.is-mobile) .workspace-split.mod-left-split .workspace-sidedock-vault-profile .workspace-drawer-vault-actions .clickable-icon,
|
||||||
7
mengyanote-frontend/public/mengyanote/.obsidian/themes/GitHub Theme/manifest.json
vendored
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
{
|
||||||
|
"name": "GitHub Theme",
|
||||||
|
"version": "1.1.6",
|
||||||
|
"minAppVersion": "1.0.0",
|
||||||
|
"author": "@krios2146",
|
||||||
|
"authorUrl": "https://github.com/krios2146"
|
||||||
|
}
|
||||||
1245
mengyanote-frontend/public/mengyanote/.obsidian/themes/GitHub Theme/theme.css
vendored
Normal file
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"name": "Minimal",
|
"name": "Minimal",
|
||||||
"version": "7.6.0",
|
"version": "8.0.4",
|
||||||
"minAppVersion": "1.6.0",
|
"minAppVersion": "1.9.0",
|
||||||
"author": "@kepano",
|
"author": "@kepano",
|
||||||
"authorUrl": "https://twitter.com/kepano",
|
"authorUrl": "https://twitter.com/kepano",
|
||||||
"fundingUrl": "https://www.buymeacoffee.com/kepano"
|
"fundingUrl": "https://www.buymeacoffee.com/kepano"
|
||||||
2251
mengyanote-frontend/public/mengyanote/.obsidian/themes/Minimal/theme.css
vendored
Normal file
@@ -7,78 +7,21 @@
|
|||||||
"id": "306ec49a61f877d3",
|
"id": "306ec49a61f877d3",
|
||||||
"type": "tabs",
|
"type": "tabs",
|
||||||
"children": [
|
"children": [
|
||||||
{
|
|
||||||
"id": "8304b0e105b08ed0",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "Docker/优秀好用的Docker镜像/NapCat-QQ机器人框架.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
},
|
|
||||||
"icon": "lucide-file",
|
|
||||||
"title": "NapCat-QQ机器人框架"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "108d0380d5e0d36b",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "Docker/优秀好用的Docker镜像/tailscale-ip-derp.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": true
|
|
||||||
},
|
|
||||||
"icon": "lucide-file",
|
|
||||||
"title": "tailscale-ip-derp"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "2971759a4871130b",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "内网穿透/Frp的kcp和quic的区别和特点.md",
|
|
||||||
"mode": "preview",
|
|
||||||
"source": true
|
|
||||||
},
|
|
||||||
"icon": "lucide-file",
|
|
||||||
"title": "Frp的kcp和quic的区别和特点"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
{
|
||||||
"id": "a93d6d3811397e7b",
|
"id": "a93d6d3811397e7b",
|
||||||
"type": "leaf",
|
"type": "leaf",
|
||||||
"state": {
|
"state": {
|
||||||
"type": "markdown",
|
"type": "markdown",
|
||||||
"state": {
|
"state": {
|
||||||
"file": "内网穿透/搭建derp和headscale避坑与指南.md",
|
"file": "Docker/优秀好用的Docker镜像/Gitea-私有化仓库部署.md",
|
||||||
"mode": "source",
|
"mode": "source",
|
||||||
"source": false
|
"source": false
|
||||||
},
|
},
|
||||||
"icon": "lucide-file",
|
"icon": "lucide-file",
|
||||||
"title": "搭建derp和headscale避坑与指南"
|
"title": "Gitea-私有化仓库部署"
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "0e0e3e5c345789e5",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "markdown",
|
|
||||||
"state": {
|
|
||||||
"file": "Docker/Docker命令集合.md",
|
|
||||||
"mode": "source",
|
|
||||||
"source": false
|
|
||||||
},
|
|
||||||
"icon": "lucide-file",
|
|
||||||
"title": "Docker命令集合"
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
]
|
||||||
"currentTab": 3
|
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"direction": "vertical"
|
"direction": "vertical"
|
||||||
@@ -110,12 +53,12 @@
|
|||||||
"state": {
|
"state": {
|
||||||
"type": "search",
|
"type": "search",
|
||||||
"state": {
|
"state": {
|
||||||
"query": "",
|
"query": "NSSM",
|
||||||
"matchingCase": false,
|
"matchingCase": false,
|
||||||
"explainSearch": false,
|
"explainSearch": false,
|
||||||
"collapseAll": false,
|
"collapseAll": false,
|
||||||
"extraContext": false,
|
"extraContext": false,
|
||||||
"sortOrder": "alphabetical"
|
"sortOrder": "alphabeticalReverse"
|
||||||
},
|
},
|
||||||
"icon": "lucide-search",
|
"icon": "lucide-search",
|
||||||
"title": "搜索"
|
"title": "搜索"
|
||||||
@@ -151,6 +94,7 @@
|
|||||||
"state": {
|
"state": {
|
||||||
"type": "backlink",
|
"type": "backlink",
|
||||||
"state": {
|
"state": {
|
||||||
|
"file": "树萌芽的小本本/树萌芽已部署网站(不定时持续更新).md",
|
||||||
"collapseAll": false,
|
"collapseAll": false,
|
||||||
"extraContext": false,
|
"extraContext": false,
|
||||||
"sortOrder": "alphabetical",
|
"sortOrder": "alphabetical",
|
||||||
@@ -160,7 +104,7 @@
|
|||||||
"unlinkedCollapsed": true
|
"unlinkedCollapsed": true
|
||||||
},
|
},
|
||||||
"icon": "links-coming-in",
|
"icon": "links-coming-in",
|
||||||
"title": "反向链接"
|
"title": "树萌芽已部署网站(不定时持续更新) 的反向链接列表"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
@@ -190,20 +134,6 @@
|
|||||||
"icon": "lucide-tags",
|
"icon": "lucide-tags",
|
||||||
"title": "标签"
|
"title": "标签"
|
||||||
}
|
}
|
||||||
},
|
|
||||||
{
|
|
||||||
"id": "5e4383b603638cf4",
|
|
||||||
"type": "leaf",
|
|
||||||
"state": {
|
|
||||||
"type": "outline",
|
|
||||||
"state": {
|
|
||||||
"followCursor": false,
|
|
||||||
"showSearch": false,
|
|
||||||
"searchQuery": ""
|
|
||||||
},
|
|
||||||
"icon": "lucide-list",
|
|
||||||
"title": "大纲"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -214,12 +144,7 @@
|
|||||||
},
|
},
|
||||||
"left-ribbon": {
|
"left-ribbon": {
|
||||||
"hiddenItems": {
|
"hiddenItems": {
|
||||||
"bases:创建新数据库": false,
|
|
||||||
"switcher:打开快速切换": false,
|
"switcher:打开快速切换": false,
|
||||||
"graph:查看关系图谱": false,
|
|
||||||
"canvas:新建白板": false,
|
|
||||||
"daily-notes:打开/创建今天的日记": false,
|
|
||||||
"templates:插入模板": false,
|
|
||||||
"command-palette:打开命令面板": false,
|
"command-palette:打开命令面板": false,
|
||||||
"obsidian-livesync:Show Log": false,
|
"obsidian-livesync:Show Log": false,
|
||||||
"obsidian-livesync:Replicate": false,
|
"obsidian-livesync:Replicate": false,
|
||||||
@@ -227,44 +152,44 @@
|
|||||||
"obsidian-livesync:Show Customization sync": false
|
"obsidian-livesync:Show Customization sync": false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"active": "f1c17e2d203acce4",
|
"active": "a93d6d3811397e7b",
|
||||||
"lastOpenFiles": [
|
"lastOpenFiles": [
|
||||||
"Terraria",
|
"编程语言/Java/JavaSpring标准项目架构.md",
|
||||||
"临时/快速开启一个http服务器.md",
|
"树萌芽的小本本/树萌芽已部署网站(不定时持续更新).md",
|
||||||
|
"Linux/ADB/ADB应用启动命令.md",
|
||||||
|
"Linux/ADB/ADB常用命令.md",
|
||||||
"树萌芽的小本本/重要信息记录.md",
|
"树萌芽的小本本/重要信息记录.md",
|
||||||
"计算机科普/IDE,编辑器,编译器区别和特点.md",
|
"树萌芽の小想法/革命后的理想.md",
|
||||||
"编程语言/前端/css注入代码合集.md",
|
"内网穿透/Wireguard/Wireguard基础命令.md",
|
||||||
|
"编程语言/Golang/Golang标准代码架构.md",
|
||||||
|
"编程语言/前端/React标准项目架构.md",
|
||||||
|
"编程语言/前端/Vue标准项目架构.md",
|
||||||
"编程语言/前端/纯静态网页的强大功能与应用.md",
|
"编程语言/前端/纯静态网页的强大功能与应用.md",
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_18.md",
|
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_28.md",
|
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_128.md",
|
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_128.md",
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_28_1756448893571.md",
|
"编程语言/前端/React项目初始化教程.md",
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_18_1756450414057.md",
|
"编程语言/前端/OpenList美化代码.md",
|
||||||
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_128_1756449169066.md",
|
"编程语言/前端/css注入代码合集.md",
|
||||||
"编程语言/前端/JavaScript趣味题/未命名",
|
"编程语言/前端/Vue项目初始化教程.md",
|
||||||
|
"编程语言/前端/代码片段/代码片段-特殊HelloWorld输出.md",
|
||||||
|
"编程语言/前端/前端html导入css和js方法.md",
|
||||||
|
"编程语言/前端/代码片段/代码片段-标准HelloWorld输出.md",
|
||||||
|
"编程语言/前端/代码片段",
|
||||||
|
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_28.md",
|
||||||
|
"编程语言/前端/React打包成Windows和Android软件方案.md",
|
||||||
|
"编程语言/前端/JavaScript趣味题/JavaScript趣味题_18.md",
|
||||||
|
"编程语言/前端/nodejs的markdown库.md",
|
||||||
|
"实习求职/面试经历/27双非本一腾讯IEG游戏安全后台实习面经.md",
|
||||||
|
"编程语言/前端/企业级标准React项目架构.md",
|
||||||
"编程语言/前端/JavaScript趣味题",
|
"编程语言/前端/JavaScript趣味题",
|
||||||
"计算机科普/编程语言之间的划分.md",
|
"实习求职/面试经历",
|
||||||
"计算机科普/游戏行业简单科普.md",
|
"编程语言/前端",
|
||||||
"计算机科普/网络协议科普.md",
|
"编程语言/前端&HTML&CSS&JS/React项目初始化教程.md",
|
||||||
"计算机科普/C,C++,CSharp,Objective-c的差异与特点.md",
|
"数据库/SQLite",
|
||||||
"计算机科普/编程语言科普.md",
|
"数据库/MongoDB",
|
||||||
"计算机科普/操作系统科普.md",
|
"数据库/MySQL",
|
||||||
"计算机科普/游戏引擎科普.md",
|
"内网穿透/Wireguard/配置/wgs-alyxg.conf",
|
||||||
"内网穿透/frp服务端配置.md",
|
"内网穿透/Wireguard/配置/wgs-alycd.conf",
|
||||||
"内网穿透/搭建derp和headscale避坑与指南.md",
|
"内网穿透/Wireguard/配置/wgc-win.conf",
|
||||||
"内网穿透/内网穿透方案.md",
|
|
||||||
"内网穿透/frp客户端配置.md",
|
|
||||||
"Docker/优秀好用的Docker镜像/frp-内网穿透神器.md",
|
|
||||||
"Docker/优秀好用的Docker镜像/模板.md",
|
|
||||||
"Docker/Docker命令集合.md",
|
|
||||||
"内网穿透",
|
|
||||||
"实习求职/面试八股/HTTP 与HTTPS",
|
|
||||||
"实习求职/面试八股",
|
|
||||||
"实习求职",
|
|
||||||
"面试八股/HTTP 与HTTPS",
|
|
||||||
"杂项",
|
|
||||||
"华为ICT/杂项",
|
|
||||||
"临时",
|
|
||||||
"Minecraft/基岩版服务器/NukkitLearn/images/5-04.png",
|
"Minecraft/基岩版服务器/NukkitLearn/images/5-04.png",
|
||||||
"Minecraft/基岩版服务器/NukkitLearn/images/5-03.png",
|
"Minecraft/基岩版服务器/NukkitLearn/images/5-03.png",
|
||||||
"Minecraft/基岩版服务器/NukkitLearn/images/5-02.png",
|
"Minecraft/基岩版服务器/NukkitLearn/images/5-02.png",
|
||||||
|
Before Width: | Height: | Size: 46 KiB After Width: | Height: | Size: 46 KiB |
|
Before Width: | Height: | Size: 66 KiB After Width: | Height: | Size: 66 KiB |
|
Before Width: | Height: | Size: 371 KiB After Width: | Height: | Size: 371 KiB |
|
Before Width: | Height: | Size: 4.9 MiB After Width: | Height: | Size: 4.9 MiB |
|
Before Width: | Height: | Size: 5.1 MiB After Width: | Height: | Size: 5.1 MiB |
|
Before Width: | Height: | Size: 4.8 MiB After Width: | Height: | Size: 4.8 MiB |
|
Before Width: | Height: | Size: 1.7 MiB After Width: | Height: | Size: 1.7 MiB |
|
Before Width: | Height: | Size: 924 KiB After Width: | Height: | Size: 924 KiB |
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 4.8 MiB After Width: | Height: | Size: 4.8 MiB |
|
Before Width: | Height: | Size: 257 KiB After Width: | Height: | Size: 257 KiB |
|
Before Width: | Height: | Size: 4.7 MiB After Width: | Height: | Size: 4.7 MiB |
|
Before Width: | Height: | Size: 2.1 MiB After Width: | Height: | Size: 2.1 MiB |
|
Before Width: | Height: | Size: 2.2 MiB After Width: | Height: | Size: 2.2 MiB |
|
Before Width: | Height: | Size: 493 KiB After Width: | Height: | Size: 493 KiB |
|
Before Width: | Height: | Size: 107 KiB After Width: | Height: | Size: 107 KiB |
117
mengyanote-frontend/public/mengyanote/.trash/Frp设置同一端口不同域名访问.md
Normal file
@@ -0,0 +1,117 @@
|
|||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 1) frps(公网服务器)配置
|
||||||
|
|
||||||
|
编辑 `frps.toml`,让 frps 监听一个 HTTP CONNECT 复用端口(你希望是 8022 就设 8022):
|
||||||
|
|
||||||
|
```toml
|
||||||
|
bindPort = 7000
|
||||||
|
|
||||||
|
# 关键:tcpmux 复用入口端口
|
||||||
|
tcpmuxHTTPConnectPort = 8022
|
||||||
|
```
|
||||||
|
|
||||||
|
重启 frps
|
||||||
|
这个 8022 **不是直接 SSH 端口**,而是“HTTP CONNECT 复用入口”
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 2) 两台内网主机的 frpc 配置
|
||||||
|
|
||||||
|
### 主机 A(big.smy.top)
|
||||||
|
|
||||||
|
`frpc.toml`:
|
||||||
|
|
||||||
|
```toml
|
||||||
|
serverAddr = "你的公网IP"
|
||||||
|
serverPort = 7000
|
||||||
|
|
||||||
|
[[proxies]]
|
||||||
|
name = "ssh_big"
|
||||||
|
type = "tcpmux"
|
||||||
|
multiplexer = "httpconnect"
|
||||||
|
customDomains = ["big.smy.top"]
|
||||||
|
localIP = "127.0.0.1"
|
||||||
|
localPort = 22
|
||||||
|
```
|
||||||
|
|
||||||
|
### 主机 B(small.smy.top)
|
||||||
|
|
||||||
|
`frpc.toml`:
|
||||||
|
|
||||||
|
```toml
|
||||||
|
serverAddr = "你的公网IP"
|
||||||
|
serverPort = 7000
|
||||||
|
|
||||||
|
[[proxies]]
|
||||||
|
name = "ssh_small"
|
||||||
|
type = "tcpmux"
|
||||||
|
multiplexer = "httpconnect"
|
||||||
|
customDomains = ["small.smy.top"]
|
||||||
|
localIP = "127.0.0.1"
|
||||||
|
localPort = 22
|
||||||
|
```
|
||||||
|
|
||||||
|
`customDomains` 就是用来区分路由的域名键
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 3) DNS 解析
|
||||||
|
|
||||||
|
把
|
||||||
|
|
||||||
|
- `big.smy.top`
|
||||||
|
- `small.smy.top`
|
||||||
|
|
||||||
|
|
||||||
|
都 **A 记录解析到同一台公网 frps 的 IP**。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 4) 连接方式
|
||||||
|
|
||||||
|
因为 tcpmux 依赖 **HTTP CONNECT** 来告诉 frps 目标域名,所以你不能这样直连:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
ssh big.smy.top -p 8022 # ❌ 这样 frps 不知道该转给谁
|
||||||
|
```
|
||||||
|
|
||||||
|
要用 ProxyCommand(官方示例用 socat):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
ssh -o 'ProxyCommand=socat - PROXY:公网IP:%h:%p,proxyport=8022' test@big.smy.top
|
||||||
|
ssh -o 'ProxyCommand=socat - PROXY:公网IP:%h:%p,proxyport=8022' test@small.smy.top
|
||||||
|
```
|
||||||
|
|
||||||
|
frps 会根据 `%h`(也就是 big / small 域名)分流到对应主机
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 5) 更舒服的用法:写到你的 `~/.ssh/config`
|
||||||
|
|
||||||
|
```sshconfig
|
||||||
|
Host big
|
||||||
|
HostName big.smy.top
|
||||||
|
User test
|
||||||
|
ProxyCommand socat - PROXY:公网IP:%h:%p,proxyport=8022
|
||||||
|
|
||||||
|
Host small
|
||||||
|
HostName small.smy.top
|
||||||
|
User test
|
||||||
|
ProxyCommand socat - PROXY:公网IP:%h:%p,proxyport=8022
|
||||||
|
```
|
||||||
|
|
||||||
|
以后直接:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
ssh big
|
||||||
|
ssh small
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
因为 SSH 本身无法携带“我要去哪个域名后端”的信息给 frps
|
||||||
|
tcpmux 是目前 frp 官方唯一的“同端口分流 SSH”方案
|
||||||
|
|
||||||
|
---
|
||||||
123
mengyanote-frontend/public/mengyanote/.trash/MongoDB添加管理员账号.md
Normal file
@@ -0,0 +1,123 @@
|
|||||||
|
|
||||||
|
接下来我们来 **一步步给 MongoDB 添加用户账户(角色管理)**。
|
||||||
|
|
||||||
|
假设你希望创建一个:
|
||||||
|
- 用户名:`shumengya`
|
||||||
|
- 密码:`shumengya520`
|
||||||
|
- 权限:对整个数据库系统有管理权限(root 权限)
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 🧭 步骤 1:进入 MongoDB Shell
|
||||||
|
|
||||||
|
MongoDB 7.x 之后使用的是新客户端 `mongosh`:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mongosh
|
||||||
|
```
|
||||||
|
|
||||||
|
如果提示 `command not found`,可以执行:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mongo
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 🧩 步骤 2:切换到 `admin` 数据库
|
||||||
|
|
||||||
|
(MongoDB 的用户管理都存在 `admin` 数据库里)
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
use admin
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 🧰 步骤 3:创建管理员用户
|
||||||
|
|
||||||
|
运行下面的命令创建一个超级管理员账号:
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
db.createUser({
|
||||||
|
user: "shumengya",
|
||||||
|
pwd: "shumengya520",
|
||||||
|
roles: [ { role: "root", db: "admin" } ]
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
✅ 成功后会输出:
|
||||||
|
|
||||||
|
```
|
||||||
|
Successfully added user: {
|
||||||
|
"user" : "shumengya",
|
||||||
|
"roles" : [ { "role" : "root", "db" : "admin" } ]
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 🔐 步骤 4:启用身份验证
|
||||||
|
|
||||||
|
编辑 MongoDB 的配置文件:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo nano /etc/mongod.conf
|
||||||
|
```
|
||||||
|
|
||||||
|
找到或添加以下部分(注意缩进):
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
security:
|
||||||
|
authorization: enabled
|
||||||
|
```
|
||||||
|
|
||||||
|
保存退出后,重启 MongoDB:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
sudo systemctl restart mongod
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## ✅ 步骤 5:验证登录是否成功
|
||||||
|
|
||||||
|
```bash
|
||||||
|
mongosh -u shumengya -p shumengya520 --authenticationDatabase admin
|
||||||
|
```
|
||||||
|
|
||||||
|
如果看到类似:
|
||||||
|
|
||||||
|
```
|
||||||
|
test>
|
||||||
|
```
|
||||||
|
|
||||||
|
说明登录成功 ✅
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 💡 可选:为特定数据库创建普通用户
|
||||||
|
|
||||||
|
比如你有个业务数据库叫 `farmgame`,可以创建普通读写用户:
|
||||||
|
|
||||||
|
```javascript
|
||||||
|
use farmgame
|
||||||
|
db.createUser({
|
||||||
|
user: "gameuser",
|
||||||
|
pwd: "gamepass123",
|
||||||
|
roles: [ { role: "readWrite", db: "farmgame" } ]
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 🧱 总结
|
||||||
|
|
||||||
|
|操作|命令或说明|
|
||||||
|
|---|---|
|
||||||
|
|创建管理员|`db.createUser({user: "shumengya", pwd: "...", roles: [{role: "root", db: "admin"}]})`|
|
||||||
|
|开启认证|`/etc/mongod.conf` → `security.authorization: enabled`|
|
||||||
|
|登录验证|`mongosh -u shumengya -p shumengya520 --authenticationDatabase admin`|
|
||||||
|
|
||||||
|
---
|
||||||
339
mengyanote-frontend/public/mengyanote/.trash/NSSM使用教程.md
Normal file
@@ -0,0 +1,339 @@
|
|||||||
|
|
||||||
|
# NSSM 使用教程(Windows 下的 systemctl 替代方案)
|
||||||
|
> 适用场景:把 **控制台程序**(如 frpc、openlist、各种 exe/bat/cmd)
|
||||||
|
> 做成 **开机自启 + 后台运行 + 崩溃自动重启 + 日志管理** 的 Windows 服务。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 目录
|
||||||
|
1. NSSM 是什么
|
||||||
|
2. 下载与准备
|
||||||
|
3. 安装服务(GUI)
|
||||||
|
4. 安装服务(纯命令行)
|
||||||
|
5. 服务启停与状态查看
|
||||||
|
6. 修改服务配置(GUI/命令行)
|
||||||
|
7. 崩溃自动重启策略
|
||||||
|
8. 日志捕获与轮转
|
||||||
|
9. 权限、依赖与进程设置(可选)
|
||||||
|
10. 卸载服务
|
||||||
|
11. 常见问题与排错
|
||||||
|
12. frpc/openlist 成品脚本示例
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 1. NSSM 是什么
|
||||||
|
NSSM(Non-Sucking Service Manager)是一个 Windows Service Wrapper,能:
|
||||||
|
- 把任何控制台程序包装成 Windows 服务
|
||||||
|
- 进程退出/崩溃时自动重启
|
||||||
|
- 捕获 stdout/stderr 写日志并支持轮转
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 2. 下载与准备
|
||||||
|
1. 下载 NSSM 压缩包,解压
|
||||||
|
2. 根据系统位数选择:
|
||||||
|
- 64 位:`win64\nssm.exe`
|
||||||
|
- 32 位:`win32\nssm.exe`
|
||||||
|
3. 放到固定目录,例如:
|
||||||
|
```
|
||||||
|
|
||||||
|
C:\tools\nssm\nssm.exe
|
||||||
|
|
||||||
|
````
|
||||||
|
4. (推荐)将 `C:\tools\nssm` 加到系统 PATH
|
||||||
|
|
||||||
|
> **注意**:后续所有安装/启动/删除服务命令,都建议在 **管理员 CMD/PowerShell** 中执行。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 3. 安装服务(GUI 最常用)
|
||||||
|
管理员 CMD:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm install frpc
|
||||||
|
````
|
||||||
|
|
||||||
|
弹出 GUI 后在 **Application** 页填写:
|
||||||
|
|
||||||
|
- **Path**:程序路径
|
||||||
|
例:`E:\控制台软件\frpc\frpc.exe`
|
||||||
|
|
||||||
|
- **Startup directory**:工作目录
|
||||||
|
例:`E:\控制台软件\frpc`
|
||||||
|
|
||||||
|
- **Arguments**:启动参数
|
||||||
|
例:`-c E:\控制台软件\frpc\frpc.ini`
|
||||||
|
|
||||||
|
|
||||||
|
填完点 **Install service**。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 4. 安装服务(纯命令行)
|
||||||
|
|
||||||
|
适合脚本化部署:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm install frpc "E:\控制台软件\frpc\frpc.exe" "-c E:\控制台软件\frpc\frpc.ini"
|
||||||
|
```
|
||||||
|
|
||||||
|
然后补充工作目录等:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppDirectory "E:\控制台软件\frpc"
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 5. 服务启停与状态查看
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm start frpc
|
||||||
|
nssm stop frpc
|
||||||
|
nssm restart frpc
|
||||||
|
nssm status frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
常见 `status` 结果:
|
||||||
|
|
||||||
|
- `SERVICE_RUNNING`:运行中
|
||||||
|
|
||||||
|
- `SERVICE_STOPPED`:已停止
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 6. 修改服务配置(GUI / 命令行)
|
||||||
|
|
||||||
|
### 6.1 GUI 编辑
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm edit frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
### 6.2 命令行修改(set/get/reset/dump)
|
||||||
|
|
||||||
|
通用格式:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set <服务名> <参数名> <值>
|
||||||
|
nssm get <服务名> <参数名>
|
||||||
|
nssm reset <服务名> <参数名>
|
||||||
|
nssm dump <服务名>
|
||||||
|
```
|
||||||
|
|
||||||
|
示例:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppDirectory "E:\控制台软件\frpc"
|
||||||
|
nssm get frpc AppDirectory
|
||||||
|
nssm dump frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 7. 崩溃自动重启策略(两层保险)
|
||||||
|
|
||||||
|
### 7.1 NSSM 自带 Exit actions
|
||||||
|
|
||||||
|
GUI:**Exit actions** 标签页
|
||||||
|
|
||||||
|
- **AppExit Default** = `Restart`
|
||||||
|
|
||||||
|
- **AppRestartDelay** = `5000`(毫秒)
|
||||||
|
|
||||||
|
- **AppThrottle** = `1500`(默认,一般不用改)
|
||||||
|
|
||||||
|
|
||||||
|
命令行等价:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppExit Default Restart
|
||||||
|
nssm set frpc AppRestartDelay 5000
|
||||||
|
nssm set frpc AppThrottle 1500
|
||||||
|
```
|
||||||
|
|
||||||
|
### 7.2 Windows 服务“恢复”策略(推荐开启)
|
||||||
|
|
||||||
|
`Win + R → services.msc`
|
||||||
|
找到服务 → 属性 → **恢复**:
|
||||||
|
|
||||||
|
- 第一次失败:重新启动服务
|
||||||
|
|
||||||
|
- 第二次失败:重新启动服务
|
||||||
|
|
||||||
|
- 后续失败:重新启动服务
|
||||||
|
|
||||||
|
- 延迟:5~10 秒
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 8. 日志捕获与轮转
|
||||||
|
|
||||||
|
### 8.1 捕获 stdout / stderr
|
||||||
|
|
||||||
|
GUI:**I/O** 页
|
||||||
|
|
||||||
|
- **Output (stdout)**:`C:\logs\frpc.out.log`
|
||||||
|
|
||||||
|
- **Error (stderr)**:`C:\logs\frpc.err.log`
|
||||||
|
|
||||||
|
|
||||||
|
命令行:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppStdout "C:\logs\frpc.out.log"
|
||||||
|
nssm set frpc AppStderr "C:\logs\frpc.err.log"
|
||||||
|
```
|
||||||
|
|
||||||
|
### 8.2 日志轮转
|
||||||
|
|
||||||
|
GUI:**File rotation** 页
|
||||||
|
|
||||||
|
- 勾 `Rotate while service is running`
|
||||||
|
|
||||||
|
- `Rotate files bigger than X bytes`(如 50MB)
|
||||||
|
|
||||||
|
- 可选勾 `Replace existing files`
|
||||||
|
|
||||||
|
|
||||||
|
命令行示例(轮转阈值 50MB):
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppRotateFiles 1
|
||||||
|
nssm set frpc AppRotateOnline 1
|
||||||
|
nssm set frpc AppRotateBytes 52428800
|
||||||
|
nssm set frpc AppRotateSeconds 0
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 9. 权限、依赖与进程设置(可选)
|
||||||
|
|
||||||
|
### 9.1 用指定账户跑服务
|
||||||
|
|
||||||
|
GUI:**Log on** 页
|
||||||
|
默认 `LocalSystem` 已够用。
|
||||||
|
需要访问网络共享时才换普通用户。
|
||||||
|
|
||||||
|
命令行:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc ObjectName ".\someuser" "password"
|
||||||
|
```
|
||||||
|
|
||||||
|
### 9.2 设置依赖(等某服务起来再启动)
|
||||||
|
|
||||||
|
GUI:**Dependencies** 页
|
||||||
|
命令行:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc DependOnService Tcpip
|
||||||
|
```
|
||||||
|
|
||||||
|
### 9.3 设置优先级/CPU 亲和性
|
||||||
|
|
||||||
|
GUI:**Process** 页
|
||||||
|
命令行:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm set frpc AppPriority NORMAL_PRIORITY_CLASS
|
||||||
|
nssm set frpc AppAffinity All
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 10. 卸载服务(安全删除)
|
||||||
|
|
||||||
|
先停再删:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm stop frpc
|
||||||
|
nssm remove frpc confirm
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 11. 常见问题与排错
|
||||||
|
|
||||||
|
### 11.1 `Can't open service! OpenService(): 拒绝访问`
|
||||||
|
|
||||||
|
原因:**没有管理员权限控制服务**
|
||||||
|
|
||||||
|
解决:
|
||||||
|
|
||||||
|
1. 关闭当前 CMD
|
||||||
|
|
||||||
|
2. 以管理员身份打开 CMD
|
||||||
|
|
||||||
|
3. 再执行:
|
||||||
|
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm start frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
### 11.2 服务启动后立刻停止
|
||||||
|
|
||||||
|
常见原因:**Path / Arguments / Startup directory 错**
|
||||||
|
|
||||||
|
排查:
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm edit frpc
|
||||||
|
nssm dump frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
### 11.3 日志没内容
|
||||||
|
|
||||||
|
原因:
|
||||||
|
|
||||||
|
- 没设置 `AppStdout/AppStderr`
|
||||||
|
|
||||||
|
- 目录没权限
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 12. frpc / openlist 成品脚本示例
|
||||||
|
|
||||||
|
### 12.1 frpc
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm install frpc "E:\控制台软件\frpc\frpc.exe" "-c \"E:\控制台软件\frpc\frpc.ini\""
|
||||||
|
nssm set frpc AppDirectory "E:\控制台软件\frpc"
|
||||||
|
nssm set frpc AppStdout "C:\logs\frpc.out.log"
|
||||||
|
nssm set frpc AppStderr "C:\logs\frpc.err.log"
|
||||||
|
nssm set frpc AppExit Default Restart
|
||||||
|
nssm set frpc AppRestartDelay 5000
|
||||||
|
nssm start frpc
|
||||||
|
```
|
||||||
|
|
||||||
|
### 12.2 openlist(按你实际参数改)
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm install openlist "E:\控制台软件\openlist\openlist.exe" "server --config E:\控制台软件\openlist\config.yaml"
|
||||||
|
nssm set openlist AppDirectory "E:\控制台软件\openlist"
|
||||||
|
nssm set openlist AppStdout "C:\logs\openlist.out.log"
|
||||||
|
nssm set openlist AppStderr "C:\logs\openlist.err.log"
|
||||||
|
nssm set openlist AppExit Default Restart
|
||||||
|
nssm set openlist AppRestartDelay 5000
|
||||||
|
nssm start openlist
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 速查表
|
||||||
|
|
||||||
|
```bat
|
||||||
|
nssm install <name> "<exe>" "<args>"
|
||||||
|
nssm edit <name>
|
||||||
|
nssm start|stop|restart <name>
|
||||||
|
nssm status <name>
|
||||||
|
nssm set/get/reset <name> <key> [value]
|
||||||
|
nssm dump <name>
|
||||||
|
nssm remove <name> confirm
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
230
mengyanote-frontend/public/mengyanote/.trash/OpenList美化代码.md
Normal file
@@ -0,0 +1,230 @@
|
|||||||
|
```html
|
||||||
|
<!-- 默认自定义头部 -->
|
||||||
|
<style>
|
||||||
|
/*隐藏底部openlsit版权信息*/
|
||||||
|
.footer span,.footer a:nth-of-type(1){
|
||||||
|
display:none;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
```html
|
||||||
|
<!-- 默认自定义头部 -->
|
||||||
|
<!-- 引入 polyfill -->
|
||||||
|
<script src="https://polyfill.alicdn.com/v3/polyfill.min.js?features=String.prototype.replaceAll"></script>
|
||||||
|
|
||||||
|
<!-- 引入字体 -->
|
||||||
|
<link rel="stylesheet" href="https://npm.elemecdn.com/lxgw-wenkai-webfont@1.1.0/lxgwwenkai-regular.css" />
|
||||||
|
|
||||||
|
<style>
|
||||||
|
/*Logo图片*/
|
||||||
|
.header-left img { filter: drop-shadow(0px 0px 20px rgb(9, 187, 189)); filter: brightness(1.5); }
|
||||||
|
|
||||||
|
|
||||||
|
/* 背景设置 */
|
||||||
|
.hope-ui-dark, .hope-ui-light {
|
||||||
|
background-image: url('https://pan.lcxm.site/d/%E7%81%B5%E5%88%9B%E7%9B%98-%E4%B8%BB%E7%9B%AE%E5%BD%95/%E7%81%B5%E5%88%9B%E7%9B%98%E7%B3%BB%E7%BB%9F%E6%96%87%E4%BB%B6/background4.png?sign=q5pQCi5TXFxY1f9ULk-Y2y4pHeIc7yulTy2e8ai_GJI=:0') !important;
|
||||||
|
background-size: cover;
|
||||||
|
background-attachment: fixed;
|
||||||
|
background-position: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*主列表白天模式透明*/
|
||||||
|
.obj-box.hope-stack.hope-c-dhzjXW.hope-c-PJLV.hope-c-PJLV-igScBhH-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(255, 255, 255, 0.3) !important;
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
/*主列表夜间模式透明*/
|
||||||
|
.obj-box.hope-stack.hope-c-dhzjXW.hope-c-PJLV.hope-c-PJLV-iigjoxS-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(0, 0, 0, 0.3) !important;
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
/*readme白天模式透明*/
|
||||||
|
.hope-c-PJLV.hope-c-PJLV-ikSuVsl-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(255, 255, 255, 0.3) !important;
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
/*readme夜间模式透明*/
|
||||||
|
.hope-c-PJLV.hope-c-PJLV-iiuDLME-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(0, 0, 0, 0.3) !important;
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
|
||||||
|
/*顶部*/
|
||||||
|
#root > .header {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background: rgba(255, 255, 255, 0); /* 透明背景色 */
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
|
||||||
|
/*导航条*/
|
||||||
|
/*白天模式*/
|
||||||
|
.hope-ui-light .body > .nav {
|
||||||
|
background-color: rgba(255, 255, 255, 0.3);
|
||||||
|
border-radius: var(--hope-radii-xl);
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
/*夜间模式*/
|
||||||
|
.hope-ui-dark .body > .nav {
|
||||||
|
background-color: rgba(0, 0, 0, 0.3);
|
||||||
|
border-radius: var(--hope-radii-xl);
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
|
||||||
|
/*隐藏导航条遮罩*/
|
||||||
|
.body > .nav::after {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*右上视图切换菜单*/
|
||||||
|
/*白天模式*/
|
||||||
|
.hope-ui-light .hope-c-PJLV-iSMXDf-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background: rgba(255, 255, 255, 0.3); /* 透明背景色 */
|
||||||
|
border-radius: 10px;
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
/*夜间模式*/
|
||||||
|
.hope-ui-dark .hope-c-PJLV-iSMXDf-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background: rgba(0, 0, 0, 0.3); /* 透明背景色 */
|
||||||
|
border-radius: var(--hope-radii-xl);
|
||||||
|
box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 阴影效果 */
|
||||||
|
}
|
||||||
|
|
||||||
|
/*右下角侧边栏按钮透明 第一个是白天 第二个是夜间*/
|
||||||
|
.hope-ui-light .hope-c-PJLV-ijgzmFG-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(255, 255, 255, 0.3) !important;
|
||||||
|
}
|
||||||
|
.hope-ui-dark .hope-c-PJLV-ijgzmFG-css {
|
||||||
|
backdrop-filter: blur(10px); /* 毛玻璃效果的强度 */
|
||||||
|
-webkit-backdrop-filter: blur(10px); /* 为 Safari 浏览器添加兼容性 */
|
||||||
|
background-color: rgba(0, 0, 0, 0.5) !important;
|
||||||
|
}
|
||||||
|
/*白天模式代码块透明*/
|
||||||
|
.hope-ui-light pre {
|
||||||
|
background-color: rgba(255, 255, 255, 0.1) !important;
|
||||||
|
}
|
||||||
|
/*夜间模式代码块透明*/
|
||||||
|
.hope-ui-dark pre {
|
||||||
|
background-color: rgba(255, 255, 255, 0) !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
/*底部CSS,.App .table这三个一起的*/
|
||||||
|
dibu {
|
||||||
|
border-top: 0px;
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
width: 100%;
|
||||||
|
margin: 0px;
|
||||||
|
padding: 0px;
|
||||||
|
}
|
||||||
|
.App {
|
||||||
|
min-height: 85vh;
|
||||||
|
}
|
||||||
|
.table {
|
||||||
|
margin: auto;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/*全局字体*/
|
||||||
|
* {
|
||||||
|
font-family: LXGW WenKai;
|
||||||
|
}
|
||||||
|
* {
|
||||||
|
font-weight: bold;
|
||||||
|
}
|
||||||
|
body {
|
||||||
|
font-family: LXGW WenKai;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
```html
|
||||||
|
<!-- 延迟加载 -->
|
||||||
|
<div id="customize" style="display: none;">
|
||||||
|
<div>
|
||||||
|
<br />
|
||||||
|
<center class="dibu">
|
||||||
|
<div style=" line-height: 20px;font-size: 20pt;font-weight: bold;">
|
||||||
|
<span>
|
||||||
|
"
|
||||||
|
<span style="color: rgb(154, 216, 166); font-weight: bold;" id="hitokoto">
|
||||||
|
<a href="#" id="hitokoto_text">
|
||||||
|
"灵创新媒实验室欢迎您!"
|
||||||
|
</a>
|
||||||
|
</span> "
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 底部链接 -->
|
||||||
|
<div style="font-size: 13px; font-weight: bold;">
|
||||||
|
<span class="nav-item">
|
||||||
|
<a class="nav-link" href="mailto:xiaoming@xmdblog.com" target="_blank">
|
||||||
|
<i class="fa-duotone fa-envelope-open" style="color:#409EFF" aria-hidden="true">
|
||||||
|
</i>
|
||||||
|
邮箱 |
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
<span class="nav-item">
|
||||||
|
<a class="nav-link" href="pan.xmdblog.com" target="_blank">
|
||||||
|
<i class="fa fa-cloud-download" style="color:#409EFF;" aria-hidden="true">
|
||||||
|
</i>
|
||||||
|
云盘 |
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
<!--后台入口-->
|
||||||
|
<span class="nav-item">
|
||||||
|
<a class="nav-link" href="/@manage" target="_blank">
|
||||||
|
<i class="fa-solid fa-folder-gear" style="color:#409EFF;" aria-hidden="true">
|
||||||
|
</i>
|
||||||
|
管理 |
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
<br />
|
||||||
|
<br />
|
||||||
|
<!--添加备案信息-->
|
||||||
|
<span class="nav-item">
|
||||||
|
<a class="nav-link" href="https://beian.miit.gov.cn/#/Integrated/index" target="_blank">
|
||||||
|
<i class="fa-solid fa-shield-check" style="color:#409EFF;" aria-hidden="true">
|
||||||
|
</i>
|
||||||
|
沪ICP备2024050492号-1
|
||||||
|
</a>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</center>
|
||||||
|
<br />
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!--延迟加载范围到这里结束-->
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<!-- 延迟加载JS -->
|
||||||
|
<script>
|
||||||
|
let interval = setInterval(() => {
|
||||||
|
if (document.querySelector(".footer")) {
|
||||||
|
document.querySelector("#customize").style.display = "";
|
||||||
|
clearInterval(interval);
|
||||||
|
}
|
||||||
|
}, 200);
|
||||||
|
</script>
|
||||||
|
```
|
||||||
|
|
||||||
|
```html
|
||||||
|
<script type="text/javascript"> function show_runtime() { window.setTimeout("show_runtime()", 1000); X = new Date("3/30/2025 12:12:12"); /*开始时间*/ Y = new Date(); T = (Y.getTime() - X.getTime()); M = 24 * 60 * 60 * 1000; a = T / M; A = Math.floor(a); b = (a - A) * 24; B = Math.floor(b); c = (b - B) * 60; C = Math.floor((b - B) * 60); D = Math.floor((c - C) * 60); runtime_span.innerHTML = "本站已运行 " + A + " 天 " + B + " 小时 " + C + " 分 " + D + " 秒 " } show_runtime(); </script>
|
||||||
|
```
|
||||||
@@ -0,0 +1,146 @@
|
|||||||
|
|
||||||
|
# 核心思路(快速决策)
|
||||||
|
|
||||||
|
- **Windows(成熟 & 快)**:用 **Electron** + `electron-builder`(或 Electron Forge)把 web 前端放进 WebView,桌面端直接运行/或同时启动本地后端进程。成熟、生态完善、发布流程(安装包、自动更新、签名)有现成方案。
|
||||||
|
- **Windows(瘦体积)**:若关心体积、原生安全,考虑 **Tauri**(Rust 后端,最终二进制更小)。但学习/环境比 Electron 略复杂。
|
||||||
|
- **Android(快 & 直接把现有 web 变原生)**:用 **Capacitor**(Ionic 团队)把生产构建的前端打包成 Android 原生工程,再用 Android Studio 打包签名上传 Play。对保留现有 React 网页最省力。
|
||||||
|
- **Android(PWA 路线,最快上线)**:如果你的 React 是 PWA(有 service worker、HTTPS、manifest),可以做 **Trusted Web Activity (TWA)**,用 Bubblewrap/PWABuilder 生成 Android 包并上架(适合想最小工作量上 Play 的场景)。
|
||||||
|
|
||||||
|
下面给出每条路线的**实战步骤、常见陷阱和示例命令**。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 路线 A — 推荐(最快、最成熟):**Electron(Windows) + Capacitor(Android)**
|
||||||
|
|
||||||
|
适合:不想重写、后端可以继续作为远端服务(推荐),要快速得到桌面 + Android 双端。
|
||||||
|
|
||||||
|
## 1) 通用准备(前端)
|
||||||
|
|
||||||
|
1. 把 React 做生产构建(示例用 CRA / Vite):
|
||||||
|
`npm run build`(或 `yarn build`),生成 `dist/` 或 `build/`。
|
||||||
|
2. 确保所有 API 用 HTTPS、CORS、并把生产 API 域配置好(不要在客户端明文放敏感秘钥)。
|
||||||
|
|
||||||
|
|
||||||
|
## 2) Windows:Electron + electron-builder(快速、成熟)
|
||||||
|
|
||||||
|
概念:Electron 启一个 native 窗口并加载你的静态 `build/`。用 `electron-builder` 打包成 installer(NSIS/MSI/portable)并可做代码签名与自动更新。
|
||||||
|
|
||||||
|
快速步骤(最小):
|
||||||
|
|
||||||
|
- 项目根目录加入 `electron` 主进程文件(`main.js`),让它加载 `build/index.html`。
|
||||||
|
- 安装依赖并配置打包:
|
||||||
|
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 依赖
|
||||||
|
npm install --save-dev electron electron-builder
|
||||||
|
# package.json scripts 示例
|
||||||
|
"scripts": {
|
||||||
|
"build:web": "npm run build", # 你的 React build
|
||||||
|
"start:electron": "electron .",
|
||||||
|
"dist": "npm run build:web && electron-builder"
|
||||||
|
},
|
||||||
|
"build": {
|
||||||
|
"appId": "com.yourcompany.app",
|
||||||
|
"files": ["build/**/*", "main.js", "package.json"],
|
||||||
|
"win": {"target":["nsis","portable"]}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
- 本地测试:`npm run start:electron`。
|
||||||
|
|
||||||
|
- 生成发布包:`npm run dist`(electron-builder 会产出 `.exe` / `.msi` / installer)。
|
||||||
|
|
||||||
|
|
||||||
|
**如果需要把后端随应用打包(可选但更复杂)**:
|
||||||
|
常见做法是把 Node 后端打成独立 exe(用 `pkg` 或 `nexe`),在 Electron 启动时用 `child_process.spawn()` 启动本地服务,再让前端调用 `http://localhost:xxxx`。这样用户本地拥有完整后端(适合离线或内网部署)。示例工具:`pkg`、`nexe`。注意:安全、端口冲突、自动更新、杀进程清理等需要处理。
|
||||||
|
|
||||||
|
常见注意点:
|
||||||
|
|
||||||
|
- Electron 应用体积通常较大(几十 MB 起);自动更新、签名(Authenticode)建议上线前完成。
|
||||||
|
- 在 CI(如 GitHub Actions)上可以交叉构建,但 Windows 的代码签名通常在 Windows runner 或专门流程中完成。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 3) Android:Capacitor(把 web 打包成原生 APK/AAB)
|
||||||
|
|
||||||
|
概念:Capacitor 将你的 `build/` 内容嵌入到一个原生 Android 项目(WebView),并提供与原生桥接的插件 API。非常适合把现有 web 转 app。
|
||||||
|
|
||||||
|
快速步骤(最小):
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 在项目根(build 已存在)
|
||||||
|
npm install @capacitor/core @capacitor/cli
|
||||||
|
npx cap init "MyApp" com.example.myapp --web-dir=build
|
||||||
|
npx cap add android
|
||||||
|
# 每次 web 有新 build:
|
||||||
|
npm run build
|
||||||
|
npx cap copy android
|
||||||
|
npx cap open android # 在 Android Studio 中打开,构建、签名、导出 AAB
|
||||||
|
```
|
||||||
|
|
||||||
|
在 Android Studio 中使用 **Build → Generate Signed Bundle / APK** 来生成签名的 AAB 上传到 Play(Play 推荐上传 AAB)。发布与签名细节见 Google Play 签名文档(Play App Signing)。
|
||||||
|
|
||||||
|
常见注意点:
|
||||||
|
|
||||||
|
- 若后端是远端 API,Android 里可直接请求远端;若需要本地 DB,使用 SQLite 或 Capacitor 的 Storage/插件而不是在设备上运行完整 Node 后端。
|
||||||
|
- 调试网络(开发时指向本地 dev server)可用 `npx cap open android` 并在 `capacitor.config.*` 设置 `server.url` 来启用 live reload(但生产请编译静态文件)。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 路线 B — 可选:**Tauri(Windows 更小) + Capacitor/TWA(Android)**
|
||||||
|
|
||||||
|
- 若你很在意桌面体积与原生安全性,**Tauri** 是比 Electron 更轻量的替代品(用 Rust 来打包、使用系统 WebView),生成的二进制更小且性能好。缺点:本地构建环境(Rust / MSVC)和插件生态比 Electron 小一些。
|
||||||
|
- Android 仍建议用 Capacitor 或 TWA 路线(Tauri 的移动支持还在发展中)。
|
||||||
|
|
||||||
|
|
||||||
|
Tauri 打包基本:`npm run build`(前端)然后 `tauri build`(生成 Windows installer / exe)——详见 Tauri 分发文档(Windows 打包细节、WebView2 要求等)。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 路线 C — 直接 PWA → Play(最快上架 Android)
|
||||||
|
|
||||||
|
如果你的 React 已经是 PWA(manifest + SW),通过 **TWA**(Trusted Web Activity)把 PWA 裹进一个最小的 Android 应用是最快的上 Play 方式:用 **Bubblewrap** / PWABuilder 生成项目,然后签名上传 Play。适合不需要本地原生 API,仅需离线缓存与简单推送的场景。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 后端打包 vs 远端服务的建议(关键设计决策)
|
||||||
|
|
||||||
|
- **优先把后端作为远端服务**(部署到云/内网)——理由:升级、补丁、数据库统一管理、安全容易;前端变体(桌面/Android/PWA)都指向同一 API,开发运维简单。
|
||||||
|
- 仅在必须(离线、内网隔离)时,把后端打包到桌面:用 `pkg` / `nexe` 做 Node -> exe,再由 Electron 启动子进程(`child_process.spawn`)。Android 上嵌入 Node 很麻烦(可选 nodejs-mobile,但生态少),因此若后端要内嵌,桌面比手机更现实。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 上线前必须做的成熟化步骤(checklist)
|
||||||
|
|
||||||
|
1. **安全**:HTTPS、CSP、Key/Secret 不放前端;XSS/CSRF/认证策略。
|
||||||
|
2. **签名与发布**:Windows 用 Authenticode 证书签名;Android 用 Play App Signing(上传签名/上传 key)。
|
||||||
|
3. **自动更新**:Electron 有 `electron-updater`/electron-builder 集成;考虑 OTA 策略。
|
||||||
|
4. **CI/CD**:用 GitHub Actions / Azure / CircleCI 自动构建 web、electron dist、Android AAB(包含签名步骤)。
|
||||||
|
5. **测试**:多架构/多机型测试、模拟断网、升级回滚测试。
|
||||||
|
6. **体积优化**:压缩静态资源、剔除 dev 依赖、考虑 Tauri 以减小 exe 体积。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 推荐组合(按你想要的结果选)
|
||||||
|
|
||||||
|
- **最快上手 + 最成熟**:Electron(Windows) + Capacitor(Android),后端保留云端。
|
||||||
|
- **追求二进制最瘦**:Tauri(Windows) + Capacitor/TWA(Android)。
|
||||||
|
- **只想最快上线到 Play(不做原生功能)**:PWA → TWA(Bubblewrap/PWABuilder)。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# 我可以直接帮你做的事(选一项即可回复)
|
||||||
|
|
||||||
|
1. 给你一份针对你 current React 项目的 **具体脚本(package.json)+ Electron 主进程示例 + electron-builder 配置**(Windows 一键打包脚本)。
|
||||||
|
2. 给你一份 **Capacitor 打包到 Android 的 step-by-step 脚本 & Android Studio 签名操作流水线**(含 AAB 签名命令示例)。
|
||||||
|
3. 或者把 **把后端打包为 exe 的示例(pkg/nexe)并在 Electron 中 spawn 的最小示例** 发给你。
|
||||||
|
|
||||||
|
告诉我你要哪一项(例如“给我 Electron + 打包脚本”),我立刻把完整代码/命令/CI 配置直接生成给你(无需你再提供额外信息即可开始)。
|
||||||
|
|
||||||
|
---
|
||||||
79
mengyanote-frontend/public/mengyanote/.trash/React项目初始化教程.md
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# ✅ **方式一:使用 Vite 初始化 React 项目(推荐,最快最轻量)**
|
||||||
|
|
||||||
|
### **1. 安装 Node.js(必须)**
|
||||||
|
|
||||||
|
确保 Node 版本 ≥ 18
|
||||||
|
检查:
|
||||||
|
```bash
|
||||||
|
node -v
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### **2. 使用 Vite 创建 React 项目**
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm create vite@latest my-react-app -- --template react
|
||||||
|
```
|
||||||
|
如果你想要 TypeScript 版本:
|
||||||
|
```bash
|
||||||
|
npm create vite@latest my-react-app -- --template react-ts
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### **3. 安装依赖**
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd my-react-app
|
||||||
|
npm install
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
### **4. 启动开发环境**
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npm run dev
|
||||||
|
```
|
||||||
|
浏览器访问提示的 localhost 地址即可。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# ✅ **方式二:使用 Create-React-App(传统方案,不推荐但能用)**
|
||||||
|
|
||||||
|
(CRA 已多年未更新,官方推荐迁移到 Vite)
|
||||||
|
|
||||||
|
### 1. 创建项目
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npx create-react-app my-react-app
|
||||||
|
```
|
||||||
|
|
||||||
|
### 2. 启动项目
|
||||||
|
|
||||||
|
```bash
|
||||||
|
cd my-react-app
|
||||||
|
npm start
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
# ✅ **方式三:使用 Next.js(如果你准备做大一点的项目)**
|
||||||
|
|
||||||
|
如果你想做:
|
||||||
|
✔ SEO
|
||||||
|
✔ 服务端渲染
|
||||||
|
✔ 大型项目结构
|
||||||
|
✔ API 路由
|
||||||
|
|
||||||
|
推荐 Next.js:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
npx create-next-app@latest
|
||||||
|
```
|
||||||
|
|
||||||
|
---
|
||||||
324
mengyanote-frontend/public/mengyanote/.trash/Vue项目初始化教程.md
Normal file
@@ -0,0 +1,324 @@
|
|||||||
|
|
||||||
|
## 1. 环境准备
|
||||||
|
|
||||||
|
### 1.1 安装Node.js
|
||||||
|
- 访问 [Node.js官网](https://nodejs.org/) 下载LTS版本
|
||||||
|
- 验证安装:
|
||||||
|
```bash
|
||||||
|
node --version
|
||||||
|
npm --version
|
||||||
|
```
|
||||||
|
|
||||||
|
### 1.2 安装Vue CLI(可选,推荐使用Vite)
|
||||||
|
```bash
|
||||||
|
npm install -g @vue/cli
|
||||||
|
# 或
|
||||||
|
yarn global add @vue/cli
|
||||||
|
```
|
||||||
|
|
||||||
|
## 2. 使用Vite创建Vue项目(推荐方式)
|
||||||
|
|
||||||
|
### 2.1 创建项目
|
||||||
|
```bash
|
||||||
|
# 使用npm
|
||||||
|
npm create vue@latest
|
||||||
|
|
||||||
|
# 或使用yarn
|
||||||
|
yarn create vue
|
||||||
|
|
||||||
|
# 或使用pnpm
|
||||||
|
pnpm create vue
|
||||||
|
```
|
||||||
|
|
||||||
|
### 2.2 交互式配置
|
||||||
|
执行命令后,你会看到以下选项:
|
||||||
|
```
|
||||||
|
✔ Project name: … <your-project-name>
|
||||||
|
✔ Add TypeScript? … No / Yes
|
||||||
|
✔ Add JSX Support? … No / Yes
|
||||||
|
✔ Add Vue Router for Single Page Application development? … No / Yes
|
||||||
|
✔ Add Pinia for state management? … No / Yes
|
||||||
|
✔ Add Vitest for Unit Testing? … No / Yes
|
||||||
|
✔ Add an End-to-End Testing Solution? … No / Cypress / Playwright
|
||||||
|
✔ Add ESLint for code quality? … No / Yes
|
||||||
|
✔ Add Prettier for code formatting? … No / Yes
|
||||||
|
```
|
||||||
|
|
||||||
|
### 2.3 进入项目并运行
|
||||||
|
```bash
|
||||||
|
cd <project-name>
|
||||||
|
npm install
|
||||||
|
npm run dev
|
||||||
|
```
|
||||||
|
|
||||||
|
## 3. 使用Vue CLI创建项目(传统方式)
|
||||||
|
|
||||||
|
### 3.1 创建项目
|
||||||
|
```bash
|
||||||
|
vue create my-project
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3.2 选择预设
|
||||||
|
```
|
||||||
|
? Please pick a preset:
|
||||||
|
Default ([Vue 2] babel, eslint)
|
||||||
|
Default (Vue 3) ([Vue 3] babel, eslint)
|
||||||
|
❯ Manually select features
|
||||||
|
```
|
||||||
|
|
||||||
|
### 3.3 选择功能
|
||||||
|
```
|
||||||
|
? Check the features needed for your project:
|
||||||
|
◉ Babel
|
||||||
|
◯ TypeScript
|
||||||
|
◯ Progressive Web App (PWA) Support
|
||||||
|
❯◉ Router
|
||||||
|
◉ Vuex
|
||||||
|
◉ CSS Pre-processors
|
||||||
|
◉ Linter / Formatter
|
||||||
|
◯ Unit Testing
|
||||||
|
◯ E2E Testing
|
||||||
|
```
|
||||||
|
|
||||||
|
## 4. 项目结构说明
|
||||||
|
|
||||||
|
使用Vite创建的典型项目结构:
|
||||||
|
```
|
||||||
|
my-vue-project/
|
||||||
|
├── node_modules/
|
||||||
|
├── public/
|
||||||
|
│ └── favicon.ico
|
||||||
|
├── src/
|
||||||
|
│ ├── assets/
|
||||||
|
│ │ └── logo.svg
|
||||||
|
│ ├── components/
|
||||||
|
│ │ └── HelloWorld.vue
|
||||||
|
│ ├── router/
|
||||||
|
│ │ └── index.js
|
||||||
|
│ ├── stores/
|
||||||
|
│ │ └── counter.js
|
||||||
|
│ ├── views/
|
||||||
|
│ │ ├── AboutView.vue
|
||||||
|
│ │ └── HomeView.vue
|
||||||
|
│ ├── App.vue
|
||||||
|
│ └── main.js
|
||||||
|
├── .gitignore
|
||||||
|
├── index.html
|
||||||
|
├── package.json
|
||||||
|
├── README.md
|
||||||
|
└── vite.config.js
|
||||||
|
```
|
||||||
|
|
||||||
|
## 5. 基础配置示例
|
||||||
|
|
||||||
|
### 5.1 修改vite.config.js
|
||||||
|
```javascript
|
||||||
|
import { defineConfig } from 'vite'
|
||||||
|
import vue from '@vitejs/plugin-vue'
|
||||||
|
import path from 'path'
|
||||||
|
|
||||||
|
export default defineConfig({
|
||||||
|
plugins: [vue()],
|
||||||
|
resolve: {
|
||||||
|
alias: {
|
||||||
|
'@': path.resolve(__dirname, './src')
|
||||||
|
}
|
||||||
|
},
|
||||||
|
server: {
|
||||||
|
port: 3000,
|
||||||
|
open: true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
```
|
||||||
|
|
||||||
|
### 5.2 配置ESLint + Prettier
|
||||||
|
`.eslintrc.cjs`:
|
||||||
|
```javascript
|
||||||
|
module.exports = {
|
||||||
|
root: true,
|
||||||
|
env: {
|
||||||
|
node: true,
|
||||||
|
browser: true,
|
||||||
|
es2021: true
|
||||||
|
},
|
||||||
|
extends: [
|
||||||
|
'eslint:recommended',
|
||||||
|
'plugin:vue/vue3-essential',
|
||||||
|
'@vue/eslint-config-prettier'
|
||||||
|
],
|
||||||
|
rules: {
|
||||||
|
'vue/multi-word-component-names': 'off'
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`.prettierrc`:
|
||||||
|
```json
|
||||||
|
{
|
||||||
|
"semi": false,
|
||||||
|
"singleQuote": true,
|
||||||
|
"printWidth": 80,
|
||||||
|
"trailingComma": "none",
|
||||||
|
"tabWidth": 2
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
## 6. 安装常用依赖
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 状态管理
|
||||||
|
npm install pinia
|
||||||
|
|
||||||
|
# UI框架(按需选择)
|
||||||
|
npm install element-plus
|
||||||
|
# 或
|
||||||
|
npm install ant-design-vue
|
||||||
|
# 或
|
||||||
|
npm install vuetify
|
||||||
|
|
||||||
|
# HTTP客户端
|
||||||
|
npm install axios
|
||||||
|
|
||||||
|
# 路由
|
||||||
|
npm install vue-router@4
|
||||||
|
|
||||||
|
# 日期处理
|
||||||
|
npm install dayjs
|
||||||
|
|
||||||
|
# 工具函数
|
||||||
|
npm install lodash-es
|
||||||
|
```
|
||||||
|
|
||||||
|
## 7. 创建第一个组件
|
||||||
|
|
||||||
|
`src/components/HelloWorld.vue`:
|
||||||
|
```vue
|
||||||
|
<template>
|
||||||
|
<div class="hello">
|
||||||
|
<h1>{{ msg }}</h1>
|
||||||
|
<button @click="count++">Count is: {{ count }}</button>
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script setup>
|
||||||
|
import { ref } from 'vue'
|
||||||
|
|
||||||
|
defineProps({
|
||||||
|
msg: String
|
||||||
|
})
|
||||||
|
|
||||||
|
const count = ref(0)
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<style scoped>
|
||||||
|
.hello {
|
||||||
|
text-align: center;
|
||||||
|
margin-top: 50px;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
```
|
||||||
|
|
||||||
|
## 8. 配置路由
|
||||||
|
|
||||||
|
`src/router/index.js`:
|
||||||
|
```javascript
|
||||||
|
import { createRouter, createWebHistory } from 'vue-router'
|
||||||
|
import HomeView from '../views/HomeView.vue'
|
||||||
|
|
||||||
|
const routes = [
|
||||||
|
{
|
||||||
|
path: '/',
|
||||||
|
name: 'home',
|
||||||
|
component: HomeView
|
||||||
|
},
|
||||||
|
{
|
||||||
|
path: '/about',
|
||||||
|
name: 'about',
|
||||||
|
component: () => import('../views/AboutView.vue')
|
||||||
|
}
|
||||||
|
]
|
||||||
|
|
||||||
|
const router = createRouter({
|
||||||
|
history: createWebHistory(),
|
||||||
|
routes
|
||||||
|
})
|
||||||
|
|
||||||
|
export default router
|
||||||
|
```
|
||||||
|
|
||||||
|
## 9. 启动和构建
|
||||||
|
|
||||||
|
```bash
|
||||||
|
# 开发模式
|
||||||
|
npm run dev
|
||||||
|
|
||||||
|
# 生产构建
|
||||||
|
npm run build
|
||||||
|
|
||||||
|
# 预览生产构建
|
||||||
|
npm run preview
|
||||||
|
|
||||||
|
# 代码检查
|
||||||
|
npm run lint
|
||||||
|
```
|
||||||
|
|
||||||
|
## 10. 最佳实践建议
|
||||||
|
|
||||||
|
### 10.1 项目组织
|
||||||
|
```
|
||||||
|
src/
|
||||||
|
├── api/ # API接口
|
||||||
|
├── assets/ # 静态资源
|
||||||
|
├── components/ # 公共组件
|
||||||
|
├── composables/ # 组合式函数
|
||||||
|
├── directives/ # 自定义指令
|
||||||
|
├── router/ # 路由配置
|
||||||
|
├── stores/ # 状态管理
|
||||||
|
├── styles/ # 全局样式
|
||||||
|
├── utils/ # 工具函数
|
||||||
|
└── views/ # 页面组件
|
||||||
|
```
|
||||||
|
|
||||||
|
### 10.2 Git提交规范
|
||||||
|
```bash
|
||||||
|
# 安装commitlint
|
||||||
|
npm install @commitlint/config-conventional @commitlint/cli -D
|
||||||
|
|
||||||
|
# 创建.commitlintrc.js
|
||||||
|
echo "module.exports = { extends: ['@commitlint/config-conventional'] }" > .commitlintrc.js
|
||||||
|
```
|
||||||
|
|
||||||
|
### 10.3 环境变量配置
|
||||||
|
创建`.env`文件:
|
||||||
|
```env
|
||||||
|
VITE_API_BASE_URL=https://api.example.com
|
||||||
|
VITE_APP_TITLE=My Vue App
|
||||||
|
```
|
||||||
|
|
||||||
|
## 常见问题
|
||||||
|
|
||||||
|
### Q: 安装缓慢?
|
||||||
|
- 使用淘宝镜像:`npm config set registry https://registry.npmmirror.com`
|
||||||
|
- 使用pnpm:`npm install -g pnpm`
|
||||||
|
|
||||||
|
### Q: 端口被占用?
|
||||||
|
```javascript
|
||||||
|
// vite.config.js
|
||||||
|
server: {
|
||||||
|
port: 3000 // 修改端口号
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Q: 需要支持旧浏览器?
|
||||||
|
```javascript
|
||||||
|
// vite.config.js
|
||||||
|
import legacy from '@vitejs/plugin-legacy'
|
||||||
|
|
||||||
|
export default {
|
||||||
|
plugins: [
|
||||||
|
legacy({
|
||||||
|
targets: ['defaults', 'not IE 11']
|
||||||
|
})
|
||||||
|
]
|
||||||
|
}
|
||||||
|
```
|
||||||
@@ -0,0 +1,3 @@
|
|||||||
|
```javascript
|
||||||
|
console.log("Hello, World!");
|
||||||
|
```
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
```javascript
|
||||||
|
//各种奇奇怪怪的方法
|
||||||
|
// 方法1: 使用Unicode转义
|
||||||
|
console.log('\u0048\u0065\u006c\u006c\u006f\u002c\u0020\u0057\u006f\u0072\u006c\u0064\u0021');
|
||||||
|
|
||||||
|
// 方法2: 使用Array和join
|
||||||
|
console.log(['Hello', 'World!'].join(', '));
|
||||||
|
|
||||||
|
// 方法3: 使用定时器
|
||||||
|
setTimeout(() => console.log('Hello, World!'), 0);
|
||||||
|
|
||||||
|
// 方法4: 使用Promise
|
||||||
|
Promise.resolve('Hello, World!').then(console.log);
|
||||||
|
|
||||||
|
// 方法5: 使用函数式编程
|
||||||
|
[].concat('Hello, World!').map(console.log);
|
||||||
|
```
|
||||||
@@ -0,0 +1,85 @@
|
|||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 1) 本地文件(Local)
|
||||||
|
|
||||||
|
**说明**:把资源放在自己服务器 / 项目目录,通过相对或绝对路径引用(`/assets/`、`./`、`../` 等)。
|
||||||
|
|
||||||
|
**示例**
|
||||||
|
|
||||||
|
```html
|
||||||
|
<!-- CSS(放 head) -->
|
||||||
|
<link rel="stylesheet" href="/css/main.css">
|
||||||
|
|
||||||
|
<!-- JS(放 body 末尾或 head + defer) -->
|
||||||
|
<script src="/js/app.js" defer></script>
|
||||||
|
```
|
||||||
|
|
||||||
|
**优点**
|
||||||
|
|
||||||
|
- 完全可控:部署、版本、更新由自己管理。
|
||||||
|
- 离线/内网可用(不依赖外部网络)。
|
||||||
|
- 容易与构建流程(hash、cache-bust)集成。
|
||||||
|
|
||||||
|
**缺点**
|
||||||
|
|
||||||
|
- 需要自己承担带宽与缓存策略。
|
||||||
|
- 同一资源不会被不同站点共享缓存(除非使用统一 CDN)。
|
||||||
|
- 初次请求可能比公共 CDN 略慢(取决于服务器配置/地域)。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 2) 网页链接 / CDN(Remote)
|
||||||
|
|
||||||
|
**说明**:引用第三方 URL(例如公用 CDN、第三方库托管),常用于库(jQuery、Bootstrap)、字体、图标或通用资源。
|
||||||
|
|
||||||
|
**示例**
|
||||||
|
|
||||||
|
```html
|
||||||
|
<!-- CSS(CDN) -->
|
||||||
|
<link rel="stylesheet" href="https://cdn.example.com/bootstrap/5.0.0/bootstrap.min.css">
|
||||||
|
|
||||||
|
<!-- JS(CDN + SRI + crossorigin) -->
|
||||||
|
<script src="https://cdn.example.com/jquery/3.7.0/jquery.min.js"
|
||||||
|
integrity="sha384-abc123..."
|
||||||
|
crossorigin="anonymous"></script>
|
||||||
|
|
||||||
|
<!-- 分析类脚本可用 async -->
|
||||||
|
<script src="https://cdn.example.com/analytics.js" async></script>
|
||||||
|
```
|
||||||
|
|
||||||
|
**优点**
|
||||||
|
|
||||||
|
- 全球分发、通常延迟更低、CDN 节点可被多站点共享缓存。
|
||||||
|
- 节省自家带宽;外部资源常有高可用性。
|
||||||
|
- 快速集成常用库(省去打包/托管工作)。
|
||||||
|
|
||||||
|
**缺点**
|
||||||
|
|
||||||
|
- 依赖第三方可用性与隐私/合规(跨域、GDPR、内网限制)。
|
||||||
|
- 安全风险:若 CDN 被劫持会影响站点(可用 SRI + crossorigin 缓解)。
|
||||||
|
- 访问受限时(企业内网、无外网环境)会失败。
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 对比速览(关键点)
|
||||||
|
|
||||||
|
- 控制权:本地 ✅✅ | CDN ✅(较弱)
|
||||||
|
- 性能(首屏/全球):CDN ✅ | 本地 视服务器而定
|
||||||
|
- 可用性(离线/内网):本地 ✅ | CDN ❌
|
||||||
|
- 缓存共享:CDN ✅ | 本地 ❌
|
||||||
|
- 安全(篡改风险):本地 ✅ | CDN 需 SRI+cors
|
||||||
|
|
||||||
|
---
|
||||||
|
|
||||||
|
## 最佳实践(简短清单)
|
||||||
|
|
||||||
|
- **CSS**:放 `<head>`;关键 CSS 可内联;非关键可 `preload` + onload 切换。
|
||||||
|
- **JS**:外部脚本优先用 `defer`(保持顺序),第三方可用 `async`(若相互独立)。
|
||||||
|
- **版本管理**:本地资源使用 hash(`app.abc123.js`)或 querystring(`?v=20251030`)做 cache-bust。
|
||||||
|
- **安全**:使用 CDN 时为第三方静态资源加 `integrity` + `crossorigin`。
|
||||||
|
- **回退/兼容**:必要时对重要外部资源提供本地回退(先尝试 CDN,失败再加载本地)。
|
||||||
|
- **隐私合规**:评估第三方脚本会不会传输用户数据,必要时加载前征得同意。
|
||||||
|
|
||||||
|
|
||||||
|
---
|
||||||
4
mengyanote-frontend/public/mengyanote/.trash/带图片.md
Normal file
@@ -0,0 +1,4 @@
|
|||||||
|
# 春日限定:
|
||||||
|
赴一场自然与生机的约会 春回大地时,万物挣脱冬日的沉寂,以最鲜活的姿态铺满视野。无论是枝头抽芽的新绿、田间绽放的繁花,还是拂面而来的暖风,都在诉说着季节的温柔絮语。
|
||||||
|
---
|
||||||
|
## 一、春日限定的自然画卷 春日的美,藏在每一处细腻的景致里。清晨的林间,露珠挂在嫩绿的叶片上,折射着柔和的晨光;午后的花海,各色花朵竞相开放,蝴蝶在花丛中翩跹起舞;傍晚的河畔,夕阳为水面镀上金边,归鸟的鸣啼伴着流水声,构成一幅宁静而治愈的画面。  *图注:清晨的林间,露珠与新绿交织出春日的清新气息* --- ## 二、解锁春日的正确打开方式 1. 踏青寻芳:走进公园、郊外或山林,沉浸式感受草木生长的力量,呼吸带着花香的新鲜空气。 2. 野餐小聚:约上好友,带着美食与餐布,在草坪上享受阳光与陪伴,记录惬意时光。 3. 绿植养护:在家中摆放几盆绿植或鲜花,让春日的生机延伸到室内,点缀日常空间。  *图注:在洒满阳光的草坪上,与好友共度轻松惬意的野餐时刻* --- ## 三、春日里的生活感悟 春天是充满希望的季节,它教会我们接纳变化、拥抱新生。就像树木在经历寒冬后重新发芽,生活也会在坚持与等待中迎来转机。不妨趁着春日正好,放慢脚步,感受身边的美好,为自己注入前行的力量。 --- 要不要我帮你生成**不同主题(如旅行、美食、读书)的带图片Markdown文章模板**?你只需告诉我具体主题,我就能快速适配内容和图片搭配。
|
||||||
@@ -75,5 +75,3 @@
|
|||||||
- **最推荐的目录:** `/usr/local/bin/`,适用于系统范围内的自定义脚本。
|
- **最推荐的目录:** `/usr/local/bin/`,适用于系统范围内的自定义脚本。
|
||||||
- **其他可选目录:** `/usr/bin/`(不推荐),如果需要放系统级命令可以选择该目录。
|
- **其他可选目录:** `/usr/bin/`(不推荐),如果需要放系统级命令可以选择该目录。
|
||||||
- **特定用户的脚本:** 用户自己的 `~/bin/` 目录。
|
- **特定用户的脚本:** 用户自己的 `~/bin/` 目录。
|
||||||
|
|
||||||
将脚本放入上述目录,并设置执行权限后,你就可以在系统中的任何地方执行该脚本了。如果有任何问题,请随时告知!
|
|
||||||
3
mengyanote-frontend/public/mengyanote/.trash/未命名.base
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
views:
|
||||||
|
- type: table
|
||||||
|
name: 表格
|
||||||
55
mengyanote-frontend/public/mengyanote/.trash/术语科普-SaaS.md
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
# 什么是 SaaS(Software as a Service)?
|
||||||
|
|
||||||
|
**一句话**:SaaS 就是把软件放在厂商的云端,通过互联网提供给你用,你按月/年订阅即可,无需自己买服务器、装软件、打补丁。
|
||||||
|
|
||||||
|
## 它和传统软件/其他“_aaS_”的区别
|
||||||
|
|
||||||
|
- **传统本地部署**:你买许可证+买服务器+自己维护 → 成本高、上线慢。
|
||||||
|
- **SaaS**:厂商托管一切(基础设施、应用、更新、备份),你用浏览器/APP直接用。
|
||||||
|
- **IaaS**(基础设施即服务):租云上的“硬件”(算力/存储/网络)。
|
||||||
|
- **PaaS**(平台即服务):租开发与运行平台(数据库/函数/中间件)。
|
||||||
|
- **SaaS**:直接是“成品应用”(如CRM、协作工具)。
|
||||||
|
|
||||||
|
## 关键特性
|
||||||
|
|
||||||
|
- 订阅计费(按用户/按用量/套餐分级)
|
||||||
|
- 通过浏览器或移动端访问,零安装
|
||||||
|
- 自动更新与弹性扩容
|
||||||
|
- 多租户架构(共享一套系统,数据逻辑隔离)
|
||||||
|
- 开放接口(API/SSO/SCIM)便于与现有系统集成
|
||||||
|
- 明确的**SLA**(可用性、支持时效)
|
||||||
|
|
||||||
|
## 优点 & 潜在不足
|
||||||
|
|
||||||
|
**优点**
|
||||||
|
|
||||||
|
- 低启动成本,快速上线
|
||||||
|
- 省运维与升级,持续获得新功能
|
||||||
|
- 按需扩缩,适合中小团队和快速试错
|
||||||
|
|
||||||
|
**潜在不足**
|
||||||
|
|
||||||
|
- 深度定制受限(更多是“配置”而非“改代码”)
|
||||||
|
- 数据合规/数据驻留要求需确认
|
||||||
|
- 依赖网络与厂商,存在一定“供应商锁定”
|
||||||
|
- 长期订阅成本需要核算
|
||||||
|
|
||||||
|
## 常见场景与例子
|
||||||
|
|
||||||
|
- 协作与沟通:Slack、Zoom、Notion
|
||||||
|
- 客户与销售:Salesforce、HubSpot
|
||||||
|
- 电商与支付:Shopify、Stripe(偏API型SaaS)
|
||||||
|
- 人事财务:Workday、QuickBooks Online
|
||||||
|
|
||||||
|
## 选型时的速查清单
|
||||||
|
|
||||||
|
1. **合规与安全**:是否支持你所在行业/地区的合规(如 ISO 27001、SOC 2、GDPR、数据驻留选项)。
|
||||||
|
2. **SLA 与可靠性**:可用性承诺、备份与灾备、支持响应时效。
|
||||||
|
3. **集成**:是否支持 SSO/SCIM、现有系统的数据同步与 API 能力。
|
||||||
|
4. **可配置度**:工作流、权限、报表、低代码/自动化能力到什么程度。
|
||||||
|
5. **数据进出**:导入/导出、数据可携带与停用后的数据处理。
|
||||||
|
6. **成本模型**:按用户/用量/功能包的组合,三年总拥有成本(TCO)。
|
||||||
|
|
||||||
|
## 一个小比喻
|
||||||
|
|
||||||
|
把软件当“自来水”:SaaS 负责建厂、铺管、净水和维护,你拧开水龙头就能用水(功能),按量付费。
|
||||||