tables.scss 6.3 KB

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