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

feat(toolbar): add pointer for icon element #974

Merged
merged 3 commits into from
Jul 21, 2017
Merged

feat(toolbar): add pointer for icon element #974

merged 3 commits into from
Jul 21, 2017

Conversation

Shyam-Chen
Copy link
Contributor

No description provided.

@codecov-io
Copy link

codecov-io commented Jul 19, 2017

Codecov Report

Merging #974 into master will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@           Coverage Diff           @@
##           master     #974   +/-   ##
=======================================
  Coverage   99.93%   99.93%           
=======================================
  Files          68       68           
  Lines        3276     3276           
  Branches      403      403           
=======================================
  Hits         3274     3274           
  Misses          2        2

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update ffb9023...ee2cfa8. Read the comment docs.

Copy link
Contributor

@yeelan0319 yeelan0319 left a comment

Choose a reason for hiding this comment

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

&__icon is separate from &__icon--menu, so we need to add this rule to both.

@Shyam-Chen
Copy link
Contributor Author

done.

@Garbee
Copy link
Contributor

Garbee commented Jul 20, 2017

This seems icky to me. The icons shouldn't trigger anything. In fact they should be pointer-events: none so they don't trigger any events in JS or anything in-accurately. It is the underlying buttons that should have the hover triggers and event listeners if any are to exist.

@yeelan0319
Copy link
Contributor

@Garbee Curious about your suggestion here "icon shouldn't trigger anything. It is the underlying buttons that should have the hover triggers". Does this means a button need to be nested within &__icon if the icon is intended to have an action? Such as:

<header class="mdc-toolbar mdc-toolbar--fixed">
  <div class="mdc-toolbar__row">
    <div class="mdc-toolbar__icon" aria-label="Download" alt="Download">
      <button><i class="material-icons">file_download</i></button>
    </div>
  </div>
</header>

IMHO, this makes toolbar structure bulkier than it is but the gain here is pretty limited, since based on the guideline that all the icons within toolbar should be actionable. Correct me if I get your meaning wrong.

@Garbee
Copy link
Contributor

Garbee commented Jul 21, 2017

Ah, I see now looking at the code more. The class naming changed some from what we were initially demoing for the component early on. This LGTM knowing that.

@yeelan0319
Copy link
Contributor

Yeah, there were some other issues related to those icons so we renamed it.
I saw you filed a couple of issues regarding the naming, let's triage them later on.

@yeelan0319 yeelan0319 merged commit 830259c into material-components:master Jul 21, 2017
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.

4 participants