Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

content does not get wrapped on mobile devices #1221

Closed
siritsch opened this issue Feb 25, 2015 · 5 comments
Closed

content does not get wrapped on mobile devices #1221

siritsch opened this issue Feb 25, 2015 · 5 comments

Comments

@siritsch
Copy link

I created the following html structure:

<core-drawer-panel id="drawerPanel">
     <core-header-panel mode="waterfall-tall" tallClass="medium-tall" drawer>
         <core-toolbar><img  height="131" src="Bilder/lotus.jpg" /></core-toolbar>
         <core-menu>
             <core-item label="One"></core-item>
             <core-item label="Two"></core-item>
         </core-menu>
    </core-header-panel>

    <core-header-panel mode="waterfall-tall" tallClass="medium-tall" main>
        <core-toolbar>
            <core-icon-button id="navicon" icon="menu">
            </core-icon-button>
            <h1>Studio Daria</h1>
            <p>...die reiche Welt der Kosmetik</p>
        </core-toolbar>
        <div class="content">
       </div>
   </core-header-panel>

If I put content inside the div element with class="content" then this content does not get wrapped on mobile devices and there is also no horizontal scrollbar available. So the content gets cut!
An example of this problem can be found under http://www.studiodaria.de/newsite/index.html .

I'm using Polymer 0.5.1

@siritsch
Copy link
Author

The body tag has the attributes "fullbleed layout vertical"

@siritsch
Copy link
Author

I now added
div[class=content] {
overflow-x: auto;
}
to the app.css file. On dektop computers and laptops it works, but on mobile devices the performance is quite poor and the scrolling behaviour is quite strange. If I want to scroll right I first have to scroll down to the bottom and then I can sroll right. To scroll back to the left I again first have to scroll down and then I can scroll left.

@davidmaxwaterman
Copy link

Seems odd to do div[class=content] - does div.content not work?

@siritsch
Copy link
Author

I also tried this. Has the same effect. Meanwhile I solved the problem with
changing the viewport parameters and I also added left and right margins
for paragraphs. The performance on mobile devices with Chrome is ok
although the initial loading takes a while. With Firefox the performance
on the same mobile device is poor. I did not try iOS devices yet.
Am 27.02.2015 18:11 schrieb "Max Waterman" [email protected]:

Seems odd to do div[class=content] - does div.content not work?


Reply to this email directly or view it on GitHub
#1221 (comment).

@davidmaxwaterman
Copy link

Glad to know it worked - it just looked weird and I wondered if there was any subtle difference I didn't know about. Anyway, I doubt it makes any difference in this case, but I think using a class selector is quite a bit faster that using an attribute selector....but I'm no expert.

Glad you fixed the problem whatever the cause :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants