【问题标题】:adding div to openseadragon Toolbar is not working [Openseadragon]将 div 添加到 openseadragon 工具栏不起作用 [Openseadragon]
【发布时间】:2017-02-27 12:56:26
【问题描述】:

当我添加收费栏(如本例中:http://openseadragon.github.io/examples/ui-toolbar/)属性时,我收到一个错误 无法读取 null 的属性“appendChild”

我只想为按钮添加一个 div 来控制它们的边距/填充

 var viewer1 = OpenSeadragon({
                 id: "mainImage",
                 maxZoomPixelRatio:6,
                toolbar:"toolbarDiv",
                panVertical:    false,
               defaultZoomLevel:    0.75,
               minZoomLevel:    0.75,
               visibilityRatio:     1,
                 preserveViewport:true, /
                 preserveImageSizeOnResize : true,
                 prefixUrl: "img",
       });

【问题讨论】:

    标签: javascript openseadragon


    【解决方案1】:

    https://github.com/openseadragon/openseadragon/issues/1140 中所述:您的页面上是否有id 为toolbarDiv 的元素?否则,您将收到该错误。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多