role.css 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138
  1. .role-info-cards-container {
  2. display: flex;
  3. flex-wrap: wrap;
  4. gap: 16px;
  5. justify-content: flex-start;
  6. }
  7. .role-item {
  8. background-color: #f9f9f9;
  9. border-radius: 8px;
  10. padding: 16px;
  11. box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
  12. width: 300px;
  13. transition: transform 0.2s ease-in-out;
  14. position: relative;
  15. }
  16. .role-item:hover {
  17. transform: scale(1.05);
  18. }
  19. .role-info-create-role-button {
  20. background-color: #007aff;
  21. color: white;
  22. border: none;
  23. padding: 10px 20px;
  24. border-radius: 10px;
  25. cursor: pointer;
  26. font-size: 16px;
  27. font-weight: 500;
  28. box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  29. transition: background-color 0.3s;
  30. margin-left: 20px;
  31. }
  32. .role-info-create-role-button:hover {
  33. background-color: #005bb5;
  34. }
  35. /* 弹出菜单样式 */
  36. #role-action-menu {
  37. position: absolute;
  38. background-color: #fff;
  39. border: 1px solid #ccc;
  40. border-radius: 5px;
  41. box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
  42. padding: 10px;
  43. z-index: 1000;
  44. }
  45. /* 模态框内按钮 */
  46. .role-info-button {
  47. padding: 10px 20px;
  48. background-color: #4CAF50;
  49. color: white;
  50. border: none;
  51. border-radius: 4px;
  52. cursor: pointer;
  53. transition: background-color 0.3s;
  54. margin-bottom: 10px;
  55. }
  56. .role-info-button:hover {
  57. background-color: #45a049;
  58. }
  59. .role-info-button-delete {
  60. background-color: #ff3b30;
  61. }
  62. .role-info-button-delete:hover {
  63. background-color: #c23321;
  64. }
  65. /*创建角色模态框*/
  66. .role-info-modal {
  67. display: none; /* 初始隐藏模态框 */
  68. position: fixed;
  69. top: 0;
  70. left: 0;
  71. right: 0;
  72. bottom: 0;
  73. background: rgba(0, 0, 0, 0.5);
  74. justify-content: center;
  75. align-items: center;
  76. z-index: 1000; /* 确保模态框在最上层 */
  77. }
  78. .role-info-modal.show {
  79. display: flex; /* 添加一个类以显示模态框 */
  80. }
  81. .createRoleModal-content {
  82. background: white;
  83. border-radius: 10px;
  84. width: 400px;
  85. padding: 20px;
  86. box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  87. }
  88. .createRoleModal-content h3 {
  89. margin: 0 0 15px 0;
  90. }
  91. .createRoleModal-content input[type="text"] {
  92. width: 100%;
  93. padding: 10px;
  94. margin-bottom: 15px;
  95. border: 1px solid #ccc;
  96. border-radius: 5px;
  97. }
  98. .createRole-buttons {
  99. display: flex;
  100. justify-content: flex-end;
  101. }
  102. .createRole-button {
  103. background-color: #007aff; /* iOS蓝色 */
  104. color: white;
  105. border: none;
  106. padding: 10px 15px;
  107. border-radius: 5px;
  108. cursor: pointer;
  109. }
  110. .createRole-button:hover {
  111. background-color: #005bb5; /* 深蓝色 */
  112. }
  113. .close-button {
  114. position: absolute;
  115. top: 10px;
  116. right: 10px;
  117. cursor: pointer;
  118. font-size: 20px;
  119. }