RocketCommunicationsInc / astro

Astro UXDS is a collection of guidelines, patterns and components for designing space-based user interface applications.
https://astrouxds.com
Other
108 stars 25 forks source link

rux-dialog message prop doesn't show when slots are used for header or footer #899

Closed micahjones13 closed 1 year ago

micahjones13 commented 1 year ago

Describe the bug When using a rux-dialog with a message prop, the message prop will not render unless the dialog is not using footer or header slots, or both.

To Reproduce Steps to reproduce the behavior:

  1. Use the following markup:
    <rux-dialog message="Message!" header="header" open>
      <div slot="footer">
        <rux-button>Hey</rux-button>
      </div>
    </rux-dialog>
  2. See that no message is rendered when it should be

Current behavior When using the message prop with a combination of slots on rux-dialog, the message does not show up.

Expected behavior A mix of slots and props should be able to be used on rux-dialog. I should see the message prop.

CodeSandbox https://codesandbox.io/s/crimson-resonance-znwk3p?file=/index.html

Environment (please complete the following information):

Additional context What's weird is that the header prop works properly, even when in use with slots. Message seems to think it's better than everyone else? EDIT: The header prop worked correctly because it's a named slot. This issue only effects default slots. This may relate to https://github.com/RocketCommunicationsInc/astro/pull/854

micahjones13 commented 1 year ago

This issue seems to also relate to https://github.com/RocketCommunicationsInc/astro/pull/854