Jump to content


Photo

Define Icons using class values

icon class value

  • Please log in to reply
2 replies to this topic

#1 k1000o

k1000o

    Advanced Member

  • Members
  • PipPipPip
  • 112 posts
  • LocationMadrid

Posted 29 May 2012 - 06:28 AM

Hello
When defining a button to launch an action we define the "class" attribute to define the type of icon we want to present.
Were can we find the different values we can use?


$content = 'CHtml::link("Delete<span class=\'icon\'></span>", "#",
array("class" => "remove",
"onclick" =>

#2 Jason

Jason

    Administrator

  • Administrators
  • 716 posts
  • LocationChicago

Posted 29 May 2012 - 02:00 PM

Let me get Amit , who worked on the icons and user interface to respond here.

Jason Green
Zurmo Team
Need support? Upgrade now


#3 Amit

Amit

    Member

  • Administrators
  • 10 posts

Posted 29 May 2012 - 02:15 PM

Hi,

In the specific case of a delete icon we're using something like this:

<a class="icon-delete" href="/index.php/home/default/DeleteDashboard?dashboardId=3" id="yt0">Delete Dashboard</a>

the style for this implementation is at newui.css around line 5057 and looks like this:



.icon-delete:before {
  content: "_";
  font-weight: normal;
  font-size: 24px;
  font-family: "ZurmoGamificationSymblyReguRg";
  padding: 0 0 0 0;
  margin: 0 10px 0 0;
  line-height: 100%;
  position: absolute;
  text-indent: -20px;
  top: 2px;
  -moz-box-sizing: border-box;
  -webkit-box-sizing: border-box;
  box-sizing: border-box;
  top: 2px;
}

So you'd want to add the class 'icon-delete' to the A tag itself, it will then render it just before the text in the link.

In theory, they're all the classes are named .icon-Something, so if you'd do a search (for .icon-) you'll find them all, another option is to search for font-family: "ZurmoGamificationSymblyReguRg"; which will show you all uses of the Icons Font we're using.





Also tagged with one or more of these keywords: icon, class, value

0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users