trading-chart.scss 2.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135
  1. .trading-chart {
  2. display: flex;
  3. flex-direction: column;
  4. background: #fff;
  5. height: 100%;
  6. &.fullscreen {
  7. position: fixed;
  8. top: 0;
  9. left: 0;
  10. right: 0;
  11. bottom: 0;
  12. z-index: 9999;
  13. }
  14. .chart-toolbar {
  15. display: flex;
  16. align-items: center;
  17. padding: 6px 12px;
  18. border-bottom: 1px solid #f0f0f0;
  19. overflow-x: auto;
  20. flex-wrap: nowrap;
  21. gap: 8px;
  22. flex-shrink: 0;
  23. &::-webkit-scrollbar {
  24. height: 0;
  25. }
  26. .interval-buttons {
  27. display: flex;
  28. gap: 2px;
  29. }
  30. .interval-btn {
  31. padding: 4px 10px;
  32. font-size: 0.75rem;
  33. font-weight: 500;
  34. color: #666;
  35. background: transparent;
  36. border: 1px solid transparent;
  37. border-radius: 3px;
  38. cursor: pointer;
  39. white-space: nowrap;
  40. transition: all 0.15s;
  41. &:hover {
  42. background: #f5f5f5;
  43. color: #333;
  44. }
  45. &.active {
  46. background: #F7931A;
  47. color: #fff;
  48. border-color: #F7931A;
  49. }
  50. }
  51. .chart-toolbar-right {
  52. display: flex;
  53. align-items: center;
  54. gap: 8px;
  55. margin-left: auto;
  56. flex-shrink: 0;
  57. }
  58. .ma-buttons {
  59. display: flex;
  60. gap: 4px;
  61. flex-shrink: 0;
  62. }
  63. .ma-btn {
  64. padding: 3px 8px;
  65. font-size: 0.7rem;
  66. font-weight: 600;
  67. color: #999;
  68. background: transparent;
  69. border: 1px solid #ddd;
  70. border-radius: 3px;
  71. cursor: pointer;
  72. white-space: nowrap;
  73. transition: all 0.15s;
  74. &:hover {
  75. border-color: #bbb;
  76. color: #666;
  77. }
  78. &.active {
  79. color: var(--ma-color);
  80. border-color: var(--ma-color);
  81. background: rgba(0, 0, 0, 0.03);
  82. }
  83. }
  84. .fullscreen-btn {
  85. display: flex;
  86. align-items: center;
  87. justify-content: center;
  88. width: 28px;
  89. height: 28px;
  90. border: 1px solid #ddd;
  91. border-radius: 3px;
  92. background: transparent;
  93. cursor: pointer;
  94. font-size: 1rem;
  95. color: #666;
  96. transition: all 0.15s;
  97. &:hover {
  98. border-color: #bbb;
  99. background: #f5f5f5;
  100. color: #333;
  101. }
  102. }
  103. }
  104. .chart-container {
  105. position: relative;
  106. width: 100%;
  107. flex: 1;
  108. min-height: 0;
  109. .chart-loading {
  110. position: absolute;
  111. top: 50%;
  112. left: 50%;
  113. transform: translate(-50%, -50%);
  114. color: #999;
  115. font-size: 0.875rem;
  116. z-index: 1;
  117. }
  118. }
  119. }