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

modal obscures dialog with overlay when inside paper-header-panel #13

Closed
tigerhawkvok opened this issue Jun 10, 2015 · 3 comments
Closed

Comments

@tigerhawkvok
Copy link

When the <paper-dialog> is created inside a paper-header-panel, the modal attribute hides the dialog behind the overlay.

It should automatically account for this.

Original bug report

Yikes!

I have a dynamically generated dialog, like so (CoffeeScript):

popupUserShippingInfo = (callback, selector = "#pp-snake") ->
  ## Irrelevant pre-setup code removed here
  # Popup paper dialog about this
  getDataHtml = """
    <paper-dialog class="paper-login" id="info-form" modal>
      <h2>Shipping Information</h2>
      <paper-dialog-scrollable id="pad-body">
        <p id="login_status"></p>
        <form>
          <paper-input label="Full Name" id="name" name="name" required auto-validate></paper-input>
          <gold-email-input id="email" name="email" required auto-validate></gold-email-input>
          <paper-input label="Street Address" required auto-validate id="street" name="street"></paper-input>
          <gold-zip-input id="zip" name="zip" required auto-validate></gold-zip-input>
          <gold-phone-input id="phone" name="phone" required auto-validate></gold-phone-input>
        </form>
      </paper-dialog-scrollable>
      <div class="buttons">
        <paper-button dialog-dismiss>Cancel</paper-button>
        <paper-button id="get-shipping">Get Shipping</paper-button>
      </div>
    </paper-dialog>
  """
  unless $("#info-form").exists()
    $("#buy-item-container").append(getDataHtml)
  ## [...] handlers ....
  $("#info-form").get(0).open()
  false

and when modal is used, I get this:

screenshot 2015-06-09 21 12 59

It works perfectly without modal, except, well, it's not modal (and since autoCloseDisabled isn't an option anymore, it means I can't have an unescapable dialog). Oddly, the z-index of the dialog is 12, and z-index = 9 for the overlay.

On Chrome Version 45.0.2421.0 dev-m (64-bit) / Windows

@wq9
Copy link

wq9 commented Jun 12, 2015

If you remove z-index: 0 (stacking context) in paper-header-panel, it works.

@tigerhawkvok
Copy link
Author

Ahhhhh. Very good insight, seeing as I hadn't mentioned I was using that!

So, it shouldn't be created inside a paper-header-panel, got it. I'll update the issue.

@tigerhawkvok tigerhawkvok changed the title modal obscures dialog with overlay modal obscures dialog with overlay when inside paper-header-panel Jun 12, 2015
@tigerhawkvok
Copy link
Author

Or not, that makes this a dup of #7 . Closing.

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