about.scss 4.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232
  1. @use 'sass:map';
  2. $progress-bar-colors: (
  3. 'blue': #048dff,
  4. 'yellow': #eebb4d,
  5. 'pink': #ed63d2,
  6. 'green': #2dca73,
  7. 'sky': #00c9e3,
  8. 'orange': #ff7c7c,
  9. );
  10. @mixin circular-progress-bar-color() {
  11. @each $color, $value in $progress-bar-colors {
  12. &.#{$color} {
  13. .circular-progress-bar {
  14. border-color: $value;
  15. }
  16. }
  17. }
  18. }
  19. @mixin circular-progress-animation-breakpoints() {
  20. $progress: 0;
  21. $duration: 0;
  22. $delay: 1.8;
  23. @for $i from 0 through 20 {
  24. .circular-progress-percentage-#{$progress} {
  25. animation: circular-loading-#{$progress} #{$duration}s linear forwards 1.8s;
  26. }
  27. .circular-progress-percentage-#{$progress}-delay {
  28. animation-delay: #{$delay}s;
  29. }
  30. $progress: $progress + 5;
  31. $duration: $duration + 0.18;
  32. $delay: $duration + 1.8;
  33. }
  34. }
  35. @mixin circular-progress-animation-keyframes($progress, $degree, $keyframes) {
  36. @for $i from 0 through $keyframes {
  37. @keyframes circular-loading-#{$progress} {
  38. 0% {
  39. transform: rotate(0);
  40. }
  41. 100% {
  42. transform: rotate(#{$degree}deg);
  43. }
  44. }
  45. $progress: $progress + 5;
  46. $degree: $degree + 18;
  47. }
  48. }
  49. .about-section {
  50. .social-link {
  51. list-style: none;
  52. padding: 0.2rem;
  53. a {
  54. font-size: 1.5rem;
  55. color: get-light-color('text-color');
  56. padding: 0.5rem;
  57. &:hover {
  58. color: get-light-color('accent-color');
  59. @include transition();
  60. }
  61. }
  62. }
  63. .circular-progress {
  64. width: 150px;
  65. height: 150px;
  66. line-height: 150px;
  67. background: none;
  68. margin: 0 auto;
  69. box-shadow: none;
  70. position: relative;
  71. &::after {
  72. content: '';
  73. width: 100%;
  74. height: 100%;
  75. border-radius: 50%;
  76. border: 12px solid get-light-color('bg-primary');
  77. position: absolute;
  78. top: 0;
  79. left: 0;
  80. }
  81. span {
  82. width: 50%;
  83. height: 100%;
  84. overflow: hidden;
  85. position: absolute;
  86. top: 0;
  87. z-index: 1;
  88. }
  89. .circular-progress-bar {
  90. width: 100%;
  91. height: 100%;
  92. background: none;
  93. border-width: 12px;
  94. border-style: solid;
  95. position: absolute;
  96. top: 0;
  97. }
  98. .circular-progress-left {
  99. left: 0;
  100. .circular-progress-bar {
  101. left: 100%;
  102. border-top-right-radius: 80px;
  103. border-bottom-right-radius: 80px;
  104. border-left: 0;
  105. transform-origin: center left;
  106. }
  107. }
  108. .circular-progress-right {
  109. right: 0;
  110. .circular-progress-bar {
  111. left: -100%;
  112. border-top-left-radius: 80px;
  113. border-bottom-left-radius: 80px;
  114. border-right: 0;
  115. transform-origin: center right;
  116. }
  117. }
  118. .circular-progress-value {
  119. width: 90%;
  120. height: 90%;
  121. padding: 1rem;
  122. border-radius: 50%;
  123. background: get-light-color('text-color');
  124. font-size: 1rem;
  125. color: get-light-color('bg-primary');
  126. line-height: initial;
  127. text-align: center;
  128. position: absolute;
  129. top: 5%;
  130. left: 5%;
  131. display: flex;
  132. justify-content: center;
  133. align-items: center;
  134. }
  135. @include circular-progress-bar-color();
  136. @include circular-progress-animation-breakpoints();
  137. @include circular-progress-animation-keyframes($progress: 0, $degree: 0, $keyframes: 20);
  138. }
  139. @include media('<=large') {
  140. .circular-progress {
  141. margin-bottom: 20px;
  142. }
  143. }
  144. @include media('<=medium') {
  145. .about-section.container {
  146. max-width: 100%;
  147. }
  148. .circular-progress {
  149. width: 135px;
  150. height: 135px;
  151. }
  152. }
  153. @include media('<=small') {
  154. .circular-progress {
  155. width: 150px;
  156. height: 150px;
  157. }
  158. .circular-progress .circular-progress-value {
  159. font-size: 1rem;
  160. }
  161. }
  162. @include media('<=tiny') {
  163. .col-6 {
  164. flex: auto;
  165. max-width: 100%;
  166. }
  167. .social-link {
  168. flex-wrap: wrap;
  169. }
  170. .certificate-badge {
  171. padding-left: 2rem;
  172. padding-right: 2rem;
  173. }
  174. .circular-progress {
  175. width: 200px;
  176. height: 200px;
  177. .circular-progress-left .circular-progress-bar {
  178. border-top-right-radius: 100px;
  179. border-bottom-right-radius: 100px;
  180. }
  181. .circular-progress-right .circular-progress-bar {
  182. border-top-left-radius: 100px;
  183. border-bottom-left-radius: 100px;
  184. }
  185. }
  186. }
  187. }
  188. html[data-theme='dark'] {
  189. .about-section {
  190. .social-link {
  191. a {
  192. color: get-dark-color('text-color');
  193. &:hover {
  194. color: get-dark-color('accent-color');
  195. }
  196. }
  197. }
  198. .circular-progress {
  199. &::after {
  200. border: 12px solid get-dark-color('bg-primary');
  201. }
  202. .circular-progress-value {
  203. background: get-dark-color('inverse-text-color');
  204. color: get-dark-color('text-color');
  205. }
  206. }
  207. }
  208. }