It there any way to scale MDL spinner? I tried to change it's widht
and height
properties, but it becomes thiner. Take a look:
CSS
width: 150px;
height: 150px
Result
It there any way to scale MDL spinner? I tried to change it's widht
and height
properties, but it becomes thiner. Take a look:
CSS
width: 150px;
height: 150px
Result
Found it.
You need to set new properties.
CSS
.mdl-spinner {
width: 28px;
height: 28px;
}
.mdl-spinner__circle {
border-width: 3px;
}
And change them in proportion 28/3. Let's say, if you want to make it 3 times bigger, your code will look like:
CSS
.mdl-spinner {
width: 84px;
height: 84px;
}
.mdl-spinner__circle {
border-width: 9px;
}
Be careful! It does affect on your FPS if scaled more than in 10 times.
I had to use !important
.
.mdl-spinner {
width: 64px !important;
height: 64px !important;
}
.mdl-spinner__circle {
border-width: 6px !important;
}
<html>
<head>
<!-- Material Design Lite -->
<script src="https://code.getmdl.io/1.3.0/material.min.js"></script>
<link rel="stylesheet" href="https://code.getmdl.io/1.3.0/material.indigo-pink.min.css">
<!-- Material Design icon font -->
<link rel="stylesheet" href="https://fonts.googleapis.com/icon?family=Material+Icons">
</head>
<body>
<!-- MDL Spinner Component -->
<div class="mdl-spinner mdl-js-spinner is-active"></div>
</body>
</html>