Pannellum: Auto Scaling Frame

Created on 19 May 2019  路  1Comment  路  Source: mpetroff/pannellum

I have been trying to get this panorama frame to scale automatically so as to fit any device but to no avail, is there a way to do this at all or is it unsupported? I have been trying to set it to 100% or auto or even blank under the #panorama tag.
index.txt

question

Most helpful comment

You need to set the size of the root element / body. The following CSS, copied from the standalone viewer, will make the viewer take up the entire page:

html {
    height: 100%;
}
body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    position: fixed;
    cursor: default;
    width: 100%;
    height: 100%;
}
#panorama {
    width: 100%;
    height: 100%;
}

>All comments

You need to set the size of the root element / body. The following CSS, copied from the standalone viewer, will make the viewer take up the entire page:

html {
    height: 100%;
}
body {
    margin: 0;
    padding: 0;
    overflow: hidden;
    position: fixed;
    cursor: default;
    width: 100%;
    height: 100%;
}
#panorama {
    width: 100%;
    height: 100%;
}
Was this page helpful?
0 / 5 - 0 ratings

Related issues

dmstern picture dmstern  路  3Comments

ThunderBoltEngineer picture ThunderBoltEngineer  路  3Comments

DStillingfleet picture DStillingfleet  路  8Comments

clarknelson picture clarknelson  路  5Comments

JamesHurburgh picture JamesHurburgh  路  3Comments