File tree Expand file tree Collapse file tree 4 files changed +33
-8
lines changed Expand file tree Collapse file tree 4 files changed +33
-8
lines changed Original file line number Diff line number Diff line change 7
7
* @markdown-confluence/lib bumped from 3.0.4 to 3.0.0
8
8
* @markdown-confluence/mermaid-electron-renderer bumped from 3.0.4 to 3.0.0
9
9
10
+ ## [ 5.2.5] ( https://github.com/markdown-confluence/markdown-confluence/compare/obsidian-confluence-v5.2.4...obsidian-confluence-v5.2.5 ) (2023-05-10)
11
+
12
+
13
+ ### Bug Fixes
14
+
15
+ * Only load CSS that exists for obsidian styles ([ c825559] ( https://github.com/markdown-confluence/markdown-confluence/commit/c825559c4c318d665996d4da0b2488666c44fcaa ) )
16
+
17
+
18
+ ### Dependencies
19
+
20
+ * The following workspace dependencies were updated
21
+ * dependencies
22
+ * @markdown-confluence/lib bumped from 5.2.4 to 5.2.5
23
+ * @markdown-confluence/mermaid-electron-renderer bumped from 5.2.4 to 5.2.5
24
+
10
25
## [ 5.2.4] ( https://github.com/markdown-confluence/markdown-confluence/compare/obsidian-confluence-v5.2.3...obsidian-confluence-v5.2.4 ) (2023-05-10)
11
26
12
27
Original file line number Diff line number Diff line change 1
1
{
2
2
"id" : " confluence-integration" ,
3
3
"name" : " Confluence Integration" ,
4
- "version" : " 5.2.4 " ,
4
+ "version" : " 5.2.5 " ,
5
5
"minAppVersion" : " 1.0.0" ,
6
6
"description" : " This plugin allows you to publish your notes to Confluence" ,
7
7
"author" : " andymac4182" ,
Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " obsidian-confluence" ,
3
- "version" : " 5.2.4 " ,
3
+ "version" : " 5.2.5 " ,
4
4
"description" : " This library allows you to publish your notes to Confluence" ,
5
5
"main" : " main.js" ,
6
6
"type" : " module" ,
24
24
"mime-types" : " ^2.1.35" ,
25
25
"react" : " ^16.14.0" ,
26
26
"react-dom" : " ^16.14.0" ,
27
- "@markdown-confluence/lib" : " 5.2.4 " ,
28
- "@markdown-confluence/mermaid-electron-renderer" : " 5.2.4 "
27
+ "@markdown-confluence/lib" : " 5.2.5 " ,
28
+ "@markdown-confluence/mermaid-electron-renderer" : " 5.2.5 "
29
29
},
30
30
"resolutions" : {
31
31
"prosemirror-model" : " 1.14.3"
Original file line number Diff line number Diff line change @@ -113,20 +113,30 @@ export default class ConfluencePlugin extends Plugin {
113
113
// @ts -expect-error
114
114
const cssTheme = this . app . vault ?. getConfig ( "cssTheme" ) as string ;
115
115
if ( cssTheme ) {
116
- const themeCss = await this . app . vault . adapter . read (
116
+ const fileExists = await this . app . vault . adapter . exists (
117
117
`.obsidian/themes/${ cssTheme } /theme.css`
118
118
) ;
119
- extraStyles . push ( themeCss ) ;
119
+ if ( fileExists ) {
120
+ const themeCss = await this . app . vault . adapter . read (
121
+ `.obsidian/themes/${ cssTheme } /theme.css`
122
+ ) ;
123
+ extraStyles . push ( themeCss ) ;
124
+ }
120
125
}
121
126
122
127
const cssSnippets =
123
128
// @ts -expect-error
124
129
( this . app . vault ?. getConfig ( "enabledCssSnippets" ) as string [ ] ) ?? [ ] ;
125
130
for ( const snippet of cssSnippets ) {
126
- const themeCss = await this . app . vault . adapter . read (
131
+ const fileExists = await this . app . vault . adapter . exists (
127
132
`.obsidian/snippets/${ snippet } .css`
128
133
) ;
129
- extraStyles . push ( themeCss ) ;
134
+ if ( fileExists ) {
135
+ const themeCss = await this . app . vault . adapter . read (
136
+ `.obsidian/snippets/${ snippet } .css`
137
+ ) ;
138
+ extraStyles . push ( themeCss ) ;
139
+ }
130
140
}
131
141
132
142
return {
You can’t perform that action at this time.
0 commit comments