Skip to content

Commit

Permalink
Merge pull request #723 from obgnail/dev
Browse files Browse the repository at this point in the history
update markmap
  • Loading branch information
obgnail authored Aug 24, 2024
2 parents fdd840c + 60c401f commit c69c558
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion plugin/export_enhance.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
class exportEnhancePlugin extends BasePlugin {
beforeProcess = async () => new Promise(resolve => {
beforeProcess = () => new Promise(resolve => {
const until = () => this.utils.exportHelper.isAsync !== undefined;
const after = () => resolve(this.utils.exportHelper.isAsync ? undefined : this.utils.stopLoadPluginError);
this.utils.loopDetector(until, after)
Expand Down
4 changes: 2 additions & 2 deletions plugin/markmap/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ class markmapPlugin extends BasePlugin {
onButtonClick = () => this.tocMarkmap && this.tocMarkmap.callback()

assignOptions = (update, old) => {
const update_ = this.utils.fromObject(update, ["spacingHorizontal", "spacingVertical", "fitRatio", "paddingX"]);
const update_ = this.utils.fromObject(update, ["spacingHorizontal", "spacingVertical", "fitRatio", "paddingX", "autoFit"]);
const options = this.MarkmapLib.deriveOptions({ ...old, ...update });
return Object.assign(options, update_)
}
Expand Down Expand Up @@ -570,7 +570,7 @@ class tocMarkmap {
{ label: "节点垂直间距", type: "range", min: 1, max: 50, step: 1, inline: true, ...KV("spacingVertical") },
{ label: "节点内部边距", type: "range", min: 1, max: 50, step: 1, inline: true, ...KV("paddingX") },
{ label: "节点最大长度", type: "range", min: 0, max: 1000, step: 10, inline: true, info: INFO.MAX_WIDTH, ...KV("maxWidth") },
{ label: "图形的窗口填充率", type: "range", min: 0.5, max: 1, step: 0.01, inline: true, ...KV("fitRatio") },
{ label: "窗口填充率", type: "range", min: 0.5, max: 1, step: 0.01, inline: true, ...KV("fitRatio") },
{ label: "动画持续时间", type: "range", min: 100, max: 1000, step: 100, inline: true, ...KV("duration") },
{ label: "定位的视口高度", type: "range", value: _localeRatio, min: 0.1, max: 1, step: 0.01, inline: true, info: INFO.LOCALE, callback: setWrapCfg("LOCALE_HEIGHT_RATIO") }
]
Expand Down

0 comments on commit c69c558

Please sign in to comment.