Sass Questions

Hi there,

I have the following code:

.abc-logo{
	height: 61px;
	width: 336px;
	
.logo-96{
		background: url(abc-logo.png);
		height: 61px;
		width: 336px;
		position: relative;
}
	
	.logo-97 {
		background: url(abc-logo.png) 0 -61px;
	height: 61px;
  width: 336px;
}

.logo-98 {
		background: url(abc-logo.png) 0 -122px;
	height: 61px;
  width: 336px;
}


.logo-99 {
		background: url(abc-logo.png) 0 -183px;
	height: 61px;
  width: 336px;
}
	

	
}

Can anyone see anyway I can simply thins using any variables etc?

Thanks!

I don’t know anything about Sass or css pre-processors, but I know as regular css it could be shortened by removing a lot of repetition.

2 Likes

abc-logo.png could be turned into a variable

$logo: "abc-logo.png";

You could do it with the width/height too I guess?

To be honest, I’d just combine those expressions with regular CSS.

This topic was automatically closed 91 days after the last reply. New replies are no longer allowed.