Skip to content

Commit

Permalink
6.0.2
Browse files Browse the repository at this point in the history
- Removed HTML and nano-id packages
  • Loading branch information
valentine195 committed Jun 22, 2021
1 parent 3617e90 commit 5752c88
Show file tree
Hide file tree
Showing 5 changed files with 12 additions and 13 deletions.
2 changes: 1 addition & 1 deletion manifest.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"id": "obsidian-admonition",
"name": "Admonition",
"version": "6.0.1",
"version": "6.0.2",
"minAppVersion": "0.11.0",
"description": "Admonition block-styled content for Obsidian.md",
"author": "Jeremy Valentine",
Expand Down
5 changes: 1 addition & 4 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "obsidian-admonition",
"version": "6.0.1",
"version": "6.0.2",
"description": "Admonition block-styled content for Obsidian.md",
"main": "main.js",
"scripts": {
Expand All @@ -18,11 +18,8 @@
"@rollup/plugin-commonjs": "^15.1.0",
"@rollup/plugin-node-resolve": "^9.0.0",
"@rollup/plugin-typescript": "^6.0.0",
"@types/html": "^1.0.0",
"@types/node": "^14.14.2",
"@types/object.fromentries": "^2.0.0",
"html": "^1.0.0",
"nanoid": "^3.1.23",
"object.fromentries": "^2.0.4",
"obsidian": "https://github.com/obsidianmd/obsidian-api/tarball/master",
"rollup": "^2.32.1",
Expand Down
8 changes: 3 additions & 5 deletions src/main.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,11 @@ import {
MarkdownRenderChild,
MarkdownRenderer,
MarkdownView,
Modal,
Notice,
Plugin,
Setting,
TFile
} from "obsidian";
import { prettyPrint as html } from "html";
/* import { prettyPrint as html } from "html"; */

import { Admonition, ObsidianAdmonitionPlugin, ISettingsData } from "./@types";
import {
Expand Down Expand Up @@ -258,7 +256,7 @@ export default class ObsidianAdmonition
}
}
});
this.addCommand({
/* this.addCommand({
id: "replace-with-html",
name: "Replace Admonitions with HTML",
callback: async () => {
Expand Down Expand Up @@ -326,7 +324,7 @@ export default class ObsidianAdmonition
);
ensure.open();
}
});
}); */

this.addCommand({
id: "insert-admonition",
Expand Down
8 changes: 6 additions & 2 deletions src/util/util.ts
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
import { MarkdownRenderer, Notice } from "obsidian";

import { nanoid } from "nanoid";
/* import { nanoid } from "nanoid"; */

import { getIconNode } from "./icons";
import { AdmonitionIconDefinition, INestedAdmonition } from "../@types";

export function getID() {
return `ID_${nanoid()}`;
return "ID_xyxyxyxyxyxy".replace(/[xy]/g, function (c) {
var r = (Math.random() * 16) | 0,
v = c == "x" ? r : (r & 0x3) | 0x8;
return v.toString(16);
});
}

export function getMatches(
Expand Down
2 changes: 1 addition & 1 deletion versions.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,5 @@
"4.3.1": "0.12.0",
"4.4.2": "0.12.2",
"5.0.3": "0.12.2",
"6.0.1": "0.12.4"
"6.0.2": "0.12.4"
}

0 comments on commit 5752c88

Please sign in to comment.