index.scss 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103
  1. .nut-progress {
  2. width: 100%;
  3. position: relative;
  4. display: flex;
  5. .nut-progress-outer {
  6. flex: 1;
  7. background-color: #f3f3f3;
  8. border-radius: 12px;
  9. height: 10px;
  10. .nut-progress-inner {
  11. width: 30%;
  12. height: 100%;
  13. border-radius: 12px;
  14. background: linear-gradient(
  15. 268deg,
  16. rgba(250, 44, 25, 1) 0%,
  17. rgba(250, 63, 25, 1) 44.59259259%,
  18. rgba(250, 89, 25, 1) 83.40740741%,
  19. rgba(250, 100, 25, 1) 100%
  20. );
  21. -webkit-transition: all 0.4s;
  22. transition: all 0.4s;
  23. position: relative;
  24. .nut-progress-text {
  25. display: flex;
  26. flex-direction: column;
  27. justify-content: center;
  28. color: #fff;
  29. }
  30. }
  31. .nut-active {
  32. &:before {
  33. content: '';
  34. position: absolute;
  35. top: 0;
  36. left: 0;
  37. right: 0;
  38. bottom: 0;
  39. border-radius: 10px;
  40. animation: progressActive 2s ease-in-out infinite;
  41. }
  42. }
  43. @keyframes progressActive {
  44. 0% {
  45. background: rgba(255, 255, 255, 0.1);
  46. width: 0;
  47. }
  48. 20% {
  49. background: rgba(255, 255, 255, 0.5);
  50. width: 0;
  51. }
  52. to {
  53. background: rgba(255, 255, 255, 0);
  54. width: 100%;
  55. }
  56. }
  57. &.nut-progress-small {
  58. height: 5px;
  59. .nut-progress-text {
  60. font-size: 7px;
  61. line-height: 10px;
  62. padding: 2px 4px;
  63. top: -100%;
  64. }
  65. }
  66. &.nut-progress-base {
  67. height: 10px;
  68. .nut-progress-text {
  69. font-size: 9px;
  70. line-height: 13px;
  71. }
  72. }
  73. &.nut-progress-large {
  74. height: 15px;
  75. .nut-progress-text {
  76. font-size: 13px;
  77. line-height: 18px;
  78. }
  79. }
  80. }
  81. .nut-progress-outer-part {
  82. width: 90%;
  83. }
  84. .nut-progress-text {
  85. padding: 0 5px;
  86. font-size: 13px;
  87. line-height: 1;
  88. }
  89. .nut-progress-insidetext {
  90. padding: 3px 5px 3px 6px;
  91. background: rgba(250, 44, 25, 1);
  92. border-radius: 5px;
  93. position: absolute;
  94. transition: all 0.4s;
  95. top: -42%;
  96. }
  97. .nut-icon-success,
  98. .nut-icon-fail {
  99. width: 10px;
  100. height: 10px;
  101. display: inline-block;
  102. }
  103. }