GithubHelp home page GithubHelp logo

Comments (5)

leeyoshinari avatar leeyoshinari commented on June 24, 2024 1

感谢,正常了

from jsmind.

hizzgdev avatar hizzgdev commented on June 24, 2024

在你这个使用场景里,只应该new一次jsmind,否则你用的那个jm对象很可能不是你希望用到的那个。

let jm = new jsMind(options); 

把这句拿出来, read_xmindsave_xmind 里都使用这个 jm 应该就没问题了。

from jsmind.

hizzgdev avatar hizzgdev commented on June 24, 2024

另外 save 之后为什么要移除 jsmind-inner 里的内容呢? 你是想清空整个脑图吗?所以这才是你需要反复new的原因?

如果是这个原因的话,可以考虑其他的处理方式,比如加上一层把脑图给挡上之类的。

from jsmind.

leeyoshinari avatar leeyoshinari commented on June 24, 2024

试过把 let jm = new jsMind(options); 拿出来只 new 一次,每次 read_xmind 时只 jm.show(data);,每次 save_xmind 时设置 display 为 none 隐藏起来,但是打开第二个文件时就页面乱了,如下图:
image

from jsmind.

hizzgdev avatar hizzgdev commented on June 24, 2024

jsmind绘图时需要知道container的尺寸,所以不要用 display:none,隐藏的话可以用 visibility:hidden

from jsmind.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.