Skip to content
This repository has been archived by the owner on Nov 9, 2022. It is now read-only.

Commit

Permalink
Add mention to extends functionality in Base/Image-Replacement [#125]
Browse files Browse the repository at this point in the history
  • Loading branch information
ebollens committed Oct 16, 2012
1 parent 825864b commit 92c861c
Showing 1 changed file with 20 additions and 2 deletions.
22 changes: 20 additions & 2 deletions doc/modules/base/Image-Replacement.md
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,37 @@ To apply image replacement to an element, add the `.ir` class to the element and
then create a CSS declaration containing the width, height, and background image to
use in image replacement. For example:

```css
h1.website-title
{
background-image: url(main-logo.png);
height: 200px;
width: 500px;
}
```

```html
<h1>Website Title</h1>
<h1 class="website-title ir">Website Title</h1>
```

When working with a SASS source file that includes WebBlocks, this can be taken
a step further using the `@extend` directive and then it is no longer necessary
to apply the `.ir` class in markup:

```css
h1
h1.website-title
{
@extend .ir;
background-image: url(main-logo.png);
height: 200px;
width: 500px;
}
```

```html
<h1 class="website-title">Website Title</h1>
```

## Responsive Considerations

None

0 comments on commit 92c861c

Please sign in to comment.