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

[class^="icon-"] selector clashes with other font lib #2

Open
emileber opened this issue Sep 26, 2016 · 0 comments
Open

[class^="icon-"] selector clashes with other font lib #2

emileber opened this issue Sep 26, 2016 · 0 comments

Comments

@emileber
Copy link
Contributor

Specifically, the following:

[class^="icon-"]:before, [class*=" icon-"]:before {
  // ...
}

clashes with Simple Line Icons as you both use icon- as a prefix.

To avoid a breaking change, I would suggest doing what the other libs do and explicitly name all the icons instead.

Something like this:

icon-cricket,
icon-bicycle,
icon-baseball,
icon-golf,
icon-skiing,
icon-soccer,
icon-swimming,
icon-tennis,
icon-theatre,
icon-football,
icon-basketball-1,
icon-pitch,
icon-badminton,
icon-rowing,
icon-rugby,
icon-archery,
icon-baking,
icon-dance,
icon-bouldering,
icon-canoe,
icon-shooting,
icon-climbing,
icon-bowl,
icon-cycling,
icon-volleyball,
icon-unichallenge,
icon-trampoline,
icon-tabletennis,
icon-squash,
icon-sail,
icon-run,
icon-pool,
icon-goal,
icon-lacrosse,
icon-martial,
icon-hockey,
icon-frisbee,
icon-handball,
icon-fencing,
icon-horse,
icon-netball,
icon-darts,
icon-fulltime,
icon-halftime,
icon-kickoff,
icon-debate,
icon-starttime,
icon-cheerleader,
icon-pokemon,
icon-computer,
icon-boxing,
icon-croquet,
icon-cinema
{
  font-family: "sports";
  font-style: normal;
  font-weight: normal;
  speak: none;

  display: inline-block;
  text-decoration: inherit;
  width: 1em;
  margin-right: .2em;
  text-align: center;
  /* opacity: .8; */

  /* For safety - reset parent styles, that can break glyph codes*/
  font-variant: normal;
  text-transform: none;

  /* fix buttons height, for twitter bootstrap */
  line-height: 1em;

  /* Animation center compensation - margins should be symmetric */
  /* remove if not needed */
  margin-left: .2em;

  /* you can be more comfortable with increased icons size */
  /* font-size: 120%; */

  /* Font smoothing. That was taken from TWBS */
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;

  /* Uncomment for 3D effect */
  /* text-shadow: 1px 1px 1px rgba(127, 127, 127, 0.3); */
}
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
@emileber and others