Skip to content

fix:(alert): updates alert - #1208

Merged
mcoker merged 2 commits into
patternfly:masterfrom
matthewcarleton:alert-updates-is1099
Jan 11, 2019
Merged

fix:(alert): updates alert#1208
mcoker merged 2 commits into
patternfly:masterfrom
matthewcarleton:alert-updates-is1099

Conversation

@matthewcarleton

Copy link
Copy Markdown
Contributor

This closes #1099

@patternfly-build

patternfly-build commented Jan 10, 2019

Copy link
Copy Markdown
Collaborator

Deploy preview for pf-next ready!

Built with commit 470d129

https://deploy-preview-1208--pf-next.netlify.com

Comment thread src/patternfly/components/Alert/alert.scss Outdated
--pf-c-alert__title--Color: var(--pf-global--Color--100);
--pf-c-alert__title__siblings--MarginTop: var(--pf-global--spacer--xs);

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would probably use --pf-c-alert__title--siblings--MarginTop since __ typically refers to a BEM element, but I don't feel strongly about it.

We do something similar with --nested

$ grep -ri 'nested--' src/
src//patternfly/components/Content/content.scss:  --pf-c-content--ul--nested--MarginTop: var(--pf-global--spacer--sm);
src//patternfly/components/Content/content.scss:  --pf-c-content--ul--nested--MarginLeft: var(--pf-global--spacer--sm);
src//patternfly/components/Content/content.scss:      margin-top: var(--pf-c-content--ul--nested--MarginTop);
src//patternfly/components/Content/content.scss:      margin-left: var(--pf-c-content--ul--nested--MarginLeft);
src//patternfly/components/List/list.scss:  --pf-c-content--ul--nested--MarginTop: var(--pf-global--spacer--sm);
src//patternfly/components/List/list.scss:  --pf-c-content--ul--nested--MarginLeft: var(--pf-global--spacer--sm);
src//patternfly/components/List/list.scss:      margin-top: var(--pf-c-content--ul--nested--MarginTop);
src//patternfly/components/List/list.scss:      margin-left: var(--pf-c-content--ul--nested--MarginLeft);

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ya I was the same. I'm cool with --

@mcoker

mcoker commented Jan 10, 2019

Copy link
Copy Markdown
Contributor

Would we ever have both a close icon and an action button in an alert?

@matthewcarleton

matthewcarleton commented Jan 10, 2019

Copy link
Copy Markdown
Contributor Author

Would we ever have both a close icon and an action button in an alert?

Not according to @mcarrano. We do have them in the alert migration demo so I've created something there. But I'd guess that we'd move that text to be a text link rather than a button beside the dismiss.

@@ -0,0 +1,6 @@
<div class="pf-c-alert__dismiss{{#if alert-dismiss--modifier}} {{alert-dismiss--modifier}}{{/if}}"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think you can remove this file now

@@ -2,6 +2,9 @@
{{#> alert-icon alert-icon--success="true"}}
{{/alert-icon}}
{{#> alert-body alert-body--attribute='role="alert"'}}
{{#> button button--modifier="pf-m-plain" button--attribute='aria-label="Remove"'}}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should the aria-label read "Close"?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh hmm...maybe? Or maybe dismiss?

{{/alert-body}}
{{/alert}}
<br>
{{#> alert alert--modifier="pf-m-success" alert--attribute='aria-label="success Notification"'}}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nitpick, can you capitalize "success Notification"?

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

Successfully merging this pull request may close these issues.

3 participants