新しいBoxサポートサイトへようこそ。 変更点の詳細はこちらをご確認ください .

Discrepancy in Displaying Logo using UI Elements - ContentExplorer vs Preview

新規投稿

コメント

3件のコメント

  • Rui Barbosa

    Hi,

    Could you add some details, screenshots and console logs?

    Is the header visible?

    Does the image displays as a broken link or not at all?

    If you try with an actual URL to an image, does it display?

    For example, this piece of code:

    HTML:

    <link href="https://cdn01.boxcdn.net/platform/preview/2.81.0/en-US/preview.css" rel="stylesheet" type="text/css"></link>
    <script src="https://cdn01.boxcdn.net/polyfills/core-js/2.5.3/core.min.js"></script>
    <script src="https://cdn01.boxcdn.net/platform/preview/2.81.0/en-US/preview.js"></script>

    <div class="previewer"></div>

     

    CSS:

    .previewer {
      border: 1px solid #eee;
      height: 500px;
      width: 100%;
    }

     

    JS:

    var configData = {
      ACCESS_TOKEN: "P1n3ID8nYMxHRWvenDatQ9k6JKzWzYrz",
        FILE_ID: '415542803939',
    }

    var options = {
      container: ".previewer",
      logoUrl:'https://ps.w.org/shortpixel-image-optimiser/assets/icon-256x256.png?rev=1038819',

    };

    /* Box Preview */
    var contentPreviewer = new Box.Preview();

    contentPreviewer.show(configData.FILE_ID, configData.ACCESS_TOKEN, options);

    Will output this:

     

    Let us know if this helps

    0
    コメントアクション Permalink
  • MARIE F

    Hi, thanks for getting back to me.
    I'm attaching screenshots of the display and console logs for your reference. 
    I've masked out portions of the URL for privacy. 
    The header shows up fine, but the image seems to be a broken link.



    Also, I tried using the logo URL from your given example in the Preview, and it displayed the same icon. 

    JS:

        const preview = new Box.Preview();
      preview.show(fileID, this.access_token, {
        container: '#' + FILE_PREVIEW_EL_CLASSNAME,
        showAnnotations: false,
        showDownload: true,
        logoUrl: 'https://ps.w.org/shortpixel-image-optimiser/assets/icon-256x256.png?rev=1038819'
        });



    Please let me know if you need any more information.

    0
    コメントアクション Permalink
  • Rui Barbosa

    Hi,

    It seems that the translation between 'box' and the actual url link is broken. I'll report it internally.

    However it does work if we populate with a proper url to an image.

    Hopefully this will work for your use case.

    Please let us know.

    Best regards

     

    0
    コメントアクション Permalink

サインインしてコメントを残してください。