tables.scss 6.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380
  1. .table {
  2. width: 100%;
  3. max-width: 100%;
  4. border-spacing: 0;
  5. border-collapse: collapse;
  6. th,
  7. td {
  8. padding: 8px;
  9. line-height: 18px;
  10. vertical-align: top;
  11. border-top: 1px solid $ui-base-color;
  12. text-align: start;
  13. background: darken($ui-base-color, 4%);
  14. &.critical {
  15. font-weight: 700;
  16. color: $gold-star;
  17. }
  18. }
  19. & > thead > tr > th {
  20. vertical-align: bottom;
  21. border-bottom: 2px solid $ui-base-color;
  22. border-top: 0;
  23. font-weight: 500;
  24. }
  25. & > tbody > tr > th {
  26. font-weight: 500;
  27. }
  28. & > tbody > tr:nth-child(odd) > td,
  29. & > tbody > tr:nth-child(odd) > th {
  30. background: $ui-base-color;
  31. }
  32. a {
  33. color: $highlight-text-color;
  34. text-decoration: underline;
  35. &:hover {
  36. text-decoration: none;
  37. }
  38. }
  39. strong {
  40. font-weight: 500;
  41. @each $lang in $cjk-langs {
  42. &:lang(#{$lang}) {
  43. font-weight: 700;
  44. }
  45. }
  46. }
  47. &.inline-table {
  48. & > tbody > tr:nth-child(odd) {
  49. & > td,
  50. & > th {
  51. background: transparent;
  52. }
  53. }
  54. & > tbody > tr:first-child {
  55. & > td,
  56. & > th {
  57. border-top: 0;
  58. }
  59. }
  60. }
  61. &.horizontal-table {
  62. border-collapse: collapse;
  63. border-style: hidden;
  64. & > tbody > tr > th,
  65. & > tbody > tr > td {
  66. padding: 11px 10px;
  67. background: transparent;
  68. border: 1px solid lighten($ui-base-color, 8%);
  69. color: $secondary-text-color;
  70. }
  71. & > tbody > tr > th {
  72. color: $darker-text-color;
  73. font-weight: 600;
  74. }
  75. }
  76. &.batch-table {
  77. & > thead > tr > th {
  78. background: $ui-base-color;
  79. border-top: 1px solid darken($ui-base-color, 8%);
  80. border-bottom: 1px solid darken($ui-base-color, 8%);
  81. &:first-child {
  82. border-radius: 4px 0 0;
  83. border-inline-start: 1px solid darken($ui-base-color, 8%);
  84. }
  85. &:last-child {
  86. border-radius: 0 4px 0 0;
  87. border-inline-end: 1px solid darken($ui-base-color, 8%);
  88. }
  89. }
  90. }
  91. &--invites tbody td {
  92. vertical-align: middle;
  93. }
  94. }
  95. .table-wrapper {
  96. overflow: auto;
  97. margin-bottom: 20px;
  98. }
  99. samp {
  100. font-family: $font-monospace, monospace;
  101. }
  102. button.table-action-link {
  103. background: transparent;
  104. border: 0;
  105. font: inherit;
  106. }
  107. button.table-action-link,
  108. a.table-action-link {
  109. text-decoration: none;
  110. display: inline-block;
  111. margin-inline-end: 5px;
  112. padding: 0 10px;
  113. color: $darker-text-color;
  114. font-weight: 500;
  115. &:hover {
  116. color: $primary-text-color;
  117. }
  118. i.fa {
  119. font-weight: 400;
  120. margin-inline-end: 5px;
  121. }
  122. &:first-child {
  123. padding-inline-start: 0;
  124. }
  125. }
  126. .batch-table {
  127. &__toolbar,
  128. &__row {
  129. display: flex;
  130. &__select {
  131. box-sizing: border-box;
  132. padding: 8px 16px;
  133. cursor: pointer;
  134. min-height: 100%;
  135. input {
  136. margin-top: 8px;
  137. }
  138. &--aligned {
  139. display: flex;
  140. align-items: center;
  141. input {
  142. margin-top: 0;
  143. }
  144. }
  145. }
  146. &__actions,
  147. &__content {
  148. padding: 8px 0;
  149. padding-inline-end: 16px;
  150. flex: 1 1 auto;
  151. }
  152. }
  153. &__toolbar {
  154. position: sticky;
  155. top: 0;
  156. z-index: 1;
  157. border: 1px solid darken($ui-base-color, 8%);
  158. background: $ui-base-color;
  159. border-radius: 4px 0 0;
  160. height: 47px;
  161. align-items: center;
  162. &__actions {
  163. text-align: end;
  164. padding-inline-end: 16px - 5px;
  165. }
  166. }
  167. &__select-all {
  168. background: $ui-base-color;
  169. height: 47px;
  170. align-items: center;
  171. justify-content: center;
  172. border: 1px solid darken($ui-base-color, 8%);
  173. border-top: 0;
  174. color: $secondary-text-color;
  175. display: none;
  176. &.active {
  177. display: flex;
  178. }
  179. .selected,
  180. .not-selected {
  181. display: none;
  182. &.active {
  183. display: block;
  184. }
  185. }
  186. strong {
  187. font-weight: 700;
  188. }
  189. span {
  190. padding: 8px;
  191. display: inline-block;
  192. }
  193. button {
  194. background: transparent;
  195. border: 0;
  196. font: inherit;
  197. color: $highlight-text-color;
  198. border-radius: 4px;
  199. font-weight: 700;
  200. padding: 8px;
  201. &:hover,
  202. &:focus,
  203. &:active {
  204. background: lighten($ui-base-color, 8%);
  205. }
  206. }
  207. }
  208. &__form {
  209. padding: 16px;
  210. border: 1px solid darken($ui-base-color, 8%);
  211. border-top: 0;
  212. background: $ui-base-color;
  213. .fields-row {
  214. padding-top: 0;
  215. margin-bottom: 0;
  216. }
  217. }
  218. &__row {
  219. border: 1px solid darken($ui-base-color, 8%);
  220. border-top: 0;
  221. background: darken($ui-base-color, 4%);
  222. @media screen and (max-width: $no-gap-breakpoint) {
  223. .optional &:first-child {
  224. border-top: 1px solid darken($ui-base-color, 8%);
  225. }
  226. }
  227. &:hover {
  228. background: darken($ui-base-color, 2%);
  229. }
  230. &:nth-child(even) {
  231. background: $ui-base-color;
  232. &:hover {
  233. background: lighten($ui-base-color, 2%);
  234. }
  235. }
  236. &__content {
  237. padding-top: 12px;
  238. padding-bottom: 16px;
  239. overflow: hidden;
  240. &--unpadded {
  241. padding: 0;
  242. }
  243. &--with-image {
  244. display: flex;
  245. align-items: center;
  246. }
  247. &__image {
  248. flex: 0 0 auto;
  249. display: flex;
  250. justify-content: center;
  251. align-items: center;
  252. margin-inline-end: 10px;
  253. .emojione {
  254. width: 32px;
  255. height: 32px;
  256. }
  257. }
  258. &__text {
  259. flex: 1 1 auto;
  260. }
  261. &__quote {
  262. padding: 12px;
  263. padding-top: 0;
  264. }
  265. &__extra {
  266. flex: 0 0 auto;
  267. text-align: end;
  268. color: $darker-text-color;
  269. font-weight: 500;
  270. }
  271. }
  272. .directory__tag {
  273. margin: 0;
  274. width: 100%;
  275. a {
  276. background: transparent;
  277. border-radius: 0;
  278. }
  279. }
  280. }
  281. &.optional .batch-table__toolbar,
  282. &.optional .batch-table__row__select {
  283. @media screen and (max-width: $no-gap-breakpoint) {
  284. display: none;
  285. }
  286. }
  287. .status__content {
  288. padding-top: 0;
  289. summary {
  290. display: list-item;
  291. }
  292. strong {
  293. font-weight: 700;
  294. }
  295. }
  296. .nothing-here {
  297. border: 1px solid darken($ui-base-color, 8%);
  298. border-top: 0;
  299. box-shadow: none;
  300. @media screen and (max-width: $no-gap-breakpoint) {
  301. border-top: 1px solid darken($ui-base-color, 8%);
  302. }
  303. }
  304. @media screen and (width <= 870px) {
  305. .accounts-table tbody td.optional {
  306. display: none;
  307. }
  308. }
  309. }
  310. .one-liner {
  311. white-space: nowrap;
  312. overflow: hidden;
  313. text-overflow: ellipsis;
  314. }