Skip to content

Commit

Permalink
release: 0.38.6
Browse files Browse the repository at this point in the history
  • Loading branch information
RyotaUshio committed Mar 18, 2024
1 parent 7cd028b commit 1c24cd3
Show file tree
Hide file tree
Showing 5 changed files with 13 additions and 7 deletions.
2 changes: 1 addition & 1 deletion manifest-beta.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "pdf-plus",
"name": "PDF++",
"version": "0.38.5",
"version": "0.38.6",
"minAppVersion": "1.4.16",
"description": "The most Obsidian-native PDF annotation tool ever.",
"author": "Ryota Ushio",
Expand Down
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "pdf-plus",
"name": "PDF++",
"version": "0.38.5",
"version": "0.38.6",
"minAppVersion": "1.4.16",
"description": "The most Obsidian-native PDF annotation tool ever.",
"author": "Ryota Ushio",
Expand Down
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "obsidian-pdf-plus",
"version": "0.38.5",
"version": "0.38.6",
"description": "The most Obsidian-native PDF annotation tool ever.",
"scripts": {
"dev": "node esbuild.config.mjs",
Expand Down
10 changes: 8 additions & 2 deletions src/modals/external-pdf-modals.ts
Original file line number Diff line number Diff line change
Expand Up @@ -308,8 +308,14 @@ export class ExternalPDFModal extends PDFPlusModal {
// So, for now, I open only the first file.
const firstFile = files.find((file): file is TFile => !!file);
if (firstFile) {
const leaf = this.app.workspace.getLeaf(true);
await leaf.openFile(firstFile);
// Again, for some reasons that I don't understand, opening the file fails without `setTimeout`.
await new Promise<void>((resolve) => {
activeWindow.setTimeout(async () => {
const leaf = this.app.workspace.getLeaf(true);
await leaf.openFile(firstFile);
resolve();
}, 300);
});
}
}

Expand Down

0 comments on commit 1c24cd3

Please sign in to comment.