project-list.less 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794
  1. @import './list/v1-import-modal.less';
  2. @announcements-shadow: 0 2px 20px rgba(0, 0, 0, 0.5);
  3. @keyframes pulse {
  4. 0% {
  5. opacity: 0.7;
  6. }
  7. 100% {
  8. opacity: 0.9;
  9. }
  10. }
  11. @keyframes fade-in {
  12. 0% {
  13. opacity: 0;
  14. }
  15. 100% {
  16. opacity: 1;
  17. }
  18. }
  19. .project-list-page {
  20. position: absolute;
  21. top: @header-height;
  22. bottom: @footer-height;
  23. padding-bottom: 0;
  24. width: 100%;
  25. overflow-x: hidden;
  26. overflow-y: auto;
  27. // Specificity needed to override default `body > .content` values
  28. body > .content& {
  29. min-height: calc(~'100vh -' (@header-height + @footer-height));
  30. padding-top: 0;
  31. }
  32. }
  33. .project-list-content when (@is-overleaf) {
  34. margin: 0;
  35. height: 100%;
  36. overflow: hidden;
  37. }
  38. .project-list-content when (@is-overleaf = false) {
  39. .container;
  40. }
  41. .project-list-empty {
  42. height: 100%;
  43. overflow-y: scroll;
  44. }
  45. .project-list-empty-col {
  46. display: flex;
  47. height: 100%;
  48. flex-direction: column;
  49. flex-wrap: nowrap;
  50. .row:first-child {
  51. flex-grow: 1; /* fill vertical space so notifications are pushed to bottom */
  52. }
  53. }
  54. .sidebar-new-proj-btn when (@is-overleaf) {
  55. .btn-block;
  56. }
  57. .project-list-row when (@is-overleaf) {
  58. height: 100%;
  59. min-height: calc(~'100vh -' (@header-height + @footer-height));
  60. }
  61. .project-list-container when (@is-overleaf) {
  62. height: 100%;
  63. }
  64. .project-list-sidebar {
  65. background-color: @sidebar-bg;
  66. padding-top: @content-margin-vertical;
  67. padding-bottom: @content-margin-vertical;
  68. color: @sidebar-color;
  69. .small {
  70. color: @sidebar-color;
  71. }
  72. }
  73. .project-list-sidebar when (@is-overleaf) {
  74. overflow-x: hidden;
  75. overflow-y: auto;
  76. -ms-overflow-style: -ms-autohiding-scrollbar;
  77. }
  78. .project-list-main {
  79. padding-top: @content-margin-vertical;
  80. padding-bottom: @content-margin-vertical;
  81. height: 100%;
  82. margin-left: -(@grid-gutter-width / 2);
  83. overflow-y: auto;
  84. }
  85. .project-header {
  86. .btn-group > .btn {
  87. padding-left: @line-height-base / 2;
  88. padding-right: @line-height-base / 2;
  89. }
  90. }
  91. .project-search {
  92. margin: @line-height-base 0;
  93. }
  94. .project-tools {
  95. display: inline;
  96. float: right;
  97. }
  98. .tags-dropdown-menu {
  99. max-width: 50vw;
  100. &.dropdown-menu > li > a {
  101. overflow: hidden;
  102. text-overflow: ellipsis;
  103. }
  104. }
  105. .project-list-table {
  106. width: 100%;
  107. table-layout: fixed;
  108. }
  109. .project-list-table-header-row {
  110. border-bottom: 1px solid @structured-list-border-color;
  111. }
  112. .project-list-table-row {
  113. position: relative;
  114. border-bottom: 1px solid @structured-list-border-color;
  115. &:last-child {
  116. border-bottom: 0 none;
  117. }
  118. &:hover {
  119. background-color: @structured-list-hover-color;
  120. }
  121. &:first-child {
  122. border-bottom-color: @structured-header-border-color;
  123. &:hover {
  124. background-color: transparent;
  125. }
  126. }
  127. }
  128. .project-list-table-name-cell,
  129. .project-list-table-owner-cell,
  130. .project-list-table-lastupdated-cell,
  131. .project-list-table-actions-cell,
  132. .project-list-table-no-projects-cell {
  133. padding: (@line-height-computed / 4) 0;
  134. vertical-align: top;
  135. }
  136. .project-list-table-no-projects-cell {
  137. text-align: center;
  138. }
  139. .project-list-table-name-cell {
  140. width: 50%;
  141. padding-right: @line-height-computed / 2;
  142. @media (min-width: @screen-md) {
  143. width: 47%;
  144. }
  145. @media (min-width: @screen-lg) {
  146. width: 50%;
  147. }
  148. }
  149. .project-list-table-name-container {
  150. position: relative;
  151. overflow: hidden;
  152. text-overflow: ellipsis;
  153. }
  154. // Extra specificity needed to override Bootstrap's own specificity.
  155. input.project-list-table-select-item[type='checkbox'] {
  156. position: absolute;
  157. left: @line-height-computed - (@grid-gutter-width / 2);
  158. margin-top: 5px;
  159. }
  160. .project-list-table-v1-badge-container {
  161. position: absolute;
  162. }
  163. .project-list-table-name {
  164. display: inline-block;
  165. padding-left: @line-height-computed * 1.5;
  166. vertical-align: top;
  167. }
  168. .project-list-table-name-link {
  169. padding: 0;
  170. }
  171. .project-list-table-owner-cell {
  172. width: 23%;
  173. padding-right: @line-height-computed / 2;
  174. overflow: hidden;
  175. text-overflow: ellipsis;
  176. @media (min-width: @screen-sm) {
  177. width: 12%;
  178. }
  179. }
  180. .project-list-table-lastupdated-cell {
  181. width: 27%;
  182. padding-right: @line-height-computed / 2;
  183. overflow: hidden;
  184. text-overflow: ellipsis;
  185. @media (min-width: @screen-sm) {
  186. width: 14%;
  187. }
  188. }
  189. .project-list-table-actions-cell {
  190. display: none;
  191. padding-right: @line-height-computed - (@grid-gutter-width / 2);
  192. text-align: right;
  193. white-space: nowrap;
  194. @media (min-width: @screen-sm) {
  195. display: table-cell;
  196. width: 18%;
  197. }
  198. @media (min-width: @screen-md) {
  199. width: 11%;
  200. }
  201. @media (min-width: @screen-lg) {
  202. width: 10%;
  203. }
  204. }
  205. .action-btn {
  206. padding: 0 0.3em;
  207. margin-left: 0.2em;
  208. }
  209. .first-project {
  210. width: 127px;
  211. text-align: center;
  212. }
  213. .user-profile {
  214. .progress {
  215. height: @line-height-computed / 2;
  216. margin-bottom: @line-height-computed / 4;
  217. }
  218. p {
  219. margin-bottom: @line-height-computed / 4;
  220. }
  221. }
  222. .user-notifications {
  223. ul {
  224. margin-bottom: 0px;
  225. }
  226. .notification-entry {
  227. .alert {
  228. .box-shadow(2px 4px 6px rgba(0, 0, 0, 0.25));
  229. display: flex;
  230. flex-wrap: wrap;
  231. @media (min-width: @screen-sm-min) {
  232. flex-wrap: nowrap;
  233. }
  234. }
  235. }
  236. }
  237. .notification-body {
  238. flex-grow: 1;
  239. width: 90%;
  240. @media (min-width: @screen-sm-min) {
  241. width: auto;
  242. }
  243. }
  244. .notification-action {
  245. margin-top: (@line-height-computed / 2); // match paragraph padding
  246. order: 1;
  247. @media (min-width: @screen-sm-min) {
  248. margin-top: 0;
  249. order: 0;
  250. padding-left: @padding-sm;
  251. }
  252. }
  253. .notification-close {
  254. padding-left: @padding-sm;
  255. text-align: right;
  256. width: 10%;
  257. @media (min-width: @screen-sm-min) {
  258. width: auto;
  259. }
  260. }
  261. ul.folders-menu {
  262. margin: @folders-menu-margin;
  263. .subdued {
  264. color: @gray-light;
  265. }
  266. > li {
  267. cursor: pointer;
  268. position: relative;
  269. > a {
  270. display: block;
  271. color: @sidebar-link-color;
  272. padding: @folders-menu-item-v-padding @folders-menu-item-h-padding;
  273. border-bottom: solid 1px transparent;
  274. &:hover {
  275. background-color: @sidebar-hover-bg;
  276. text-decoration: @sidebar-hover-text-decoration;
  277. }
  278. &:focus {
  279. text-decoration: none;
  280. }
  281. }
  282. > a when (@is-overleaf = false) {
  283. font-size: 0.9rem;
  284. }
  285. &.separator {
  286. padding: @folders-menu-item-v-padding @folders-menu-item-h-padding;
  287. cursor: auto;
  288. }
  289. }
  290. > li.active {
  291. border-radius: @sidebar-active-border-radius;
  292. > a {
  293. background-color: @sidebar-active-bg;
  294. font-weight: @sidebar-active-font-weight;
  295. color: @sidebar-active-color;
  296. .subdued {
  297. color: @sidebar-active-color;
  298. }
  299. }
  300. }
  301. > li.folders-menu-item-with-tooltip {
  302. > a {
  303. padding-right: 1.5 * @folders-menu-item-h-padding +
  304. @folders-menu-tooltip-size;
  305. }
  306. }
  307. > li > a.small {
  308. color: @gray;
  309. }
  310. h2 {
  311. margin-top: @folders-title-margin-top;
  312. margin-bottom: @folders-title-margin-bottom;
  313. font-size: @folders-title-font-size;
  314. color: @folders-title-color;
  315. text-transform: @folders-title-text-transform;
  316. padding: @folders-title-padding;
  317. font-weight: @folders-title-font-weight;
  318. font-family: @font-family-sans-serif;
  319. }
  320. > li.tag {
  321. &.active {
  322. .tag-menu > a {
  323. color: white;
  324. border-color: white;
  325. &:hover {
  326. background-color: @folders-tag-menu-active-hover;
  327. }
  328. }
  329. }
  330. &.untagged {
  331. a.tag-name {
  332. span.name {
  333. font-style: italic;
  334. padding-left: 0;
  335. }
  336. }
  337. }
  338. &:hover {
  339. &:not(.active) {
  340. background-color: @folders-tag-hover;
  341. }
  342. .tag-menu {
  343. display: block;
  344. }
  345. }
  346. &:not(.active) {
  347. .tag-menu > a:hover {
  348. background-color: @folders-tag-menu-hover;
  349. }
  350. }
  351. a.tag-name {
  352. position: relative;
  353. padding: @folders-tag-padding;
  354. display: @folders-tag-display;
  355. span.name {
  356. padding-left: 0.5em;
  357. line-height: @folders-tag-line-height;
  358. }
  359. }
  360. .tag-menu {
  361. > a {
  362. border: 1px solid @folders-tag-border-color;
  363. border-radius: @border-radius-small;
  364. color: @folders-tag-menu-color;
  365. display: block;
  366. width: 16px;
  367. height: 16px;
  368. position: relative;
  369. .caret {
  370. position: absolute;
  371. top: 6px;
  372. left: 1px;
  373. }
  374. }
  375. display: none;
  376. position: absolute;
  377. top: 50%;
  378. margin-top: -8px; // Half the element height.
  379. right: 4px;
  380. &.open {
  381. display: block;
  382. }
  383. }
  384. }
  385. }
  386. .folders-menu-tooltip-trigger {
  387. display: none;
  388. position: absolute;
  389. top: 50%;
  390. right: @folders-menu-item-h-padding;
  391. width: @folders-menu-tooltip-size;
  392. height: @folders-menu-tooltip-size;
  393. margin-top: -(floor(@folders-menu-tooltip-size / 2));
  394. line-height: @folders-menu-tooltip-size;
  395. background-color: @folders-menu-tooltip-bg;
  396. font-family: @font-family-serif;
  397. color: #fff;
  398. font-style: italic;
  399. border-radius: ceil(@folders-menu-tooltip-size / 2);
  400. text-align: center;
  401. font-weight: 700;
  402. @media (min-width: @screen-sm-min) {
  403. display: block;
  404. }
  405. }
  406. .project-action-alert {
  407. display: flex;
  408. margin-bottom: 0;
  409. align-items: center;
  410. }
  411. .project-action-alert-msg {
  412. flex-grow: 1;
  413. padding-right: 10px;
  414. }
  415. form.project-search {
  416. .form-group {
  417. margin-bottom: 0;
  418. }
  419. }
  420. ul.structured-list {
  421. list-style-type: none;
  422. margin: 0;
  423. overflow: hidden;
  424. overflow-y: auto;
  425. -ms-overflow-style: -ms-autohiding-scrollbar;
  426. li {
  427. border-bottom: 1px solid @structured-list-border-color;
  428. padding: (@line-height-computed / 4) 0;
  429. &:last-child {
  430. border-bottom: 0 none;
  431. }
  432. &:hover {
  433. background-color: @structured-list-hover-color;
  434. }
  435. &:first-child {
  436. border-bottom-color: @structured-header-border-color;
  437. &:hover {
  438. background-color: transparent;
  439. }
  440. }
  441. a {
  442. color: @structured-list-link-color;
  443. }
  444. .header when (@is-overleaf = true) {
  445. font-weight: 600;
  446. }
  447. .header when (@is-overleaf = false) {
  448. text-transform: uppercase;
  449. }
  450. .select-item,
  451. .select-all {
  452. position: absolute;
  453. left: @line-height-computed;
  454. }
  455. .select-item + span,
  456. .select-all + span {
  457. display: inline-block;
  458. padding-left: @line-height-computed * 1.5;
  459. max-width: 100%;
  460. overflow: hidden;
  461. text-overflow: ellipsis;
  462. vertical-align: top;
  463. }
  464. }
  465. }
  466. .project-list-card when (@is-overleaf) {
  467. padding: 0 (@line-height-computed / 4);
  468. }
  469. ul.project-list {
  470. li {
  471. .last-modified when (@is-overleaf = false) {
  472. font-size: 0.8rem;
  473. }
  474. .owner when (@is-overleaf = false) {
  475. font-size: 0.8rem;
  476. }
  477. .owner when (@is-overleaf = false) {
  478. margin-right: 0;
  479. }
  480. .projectName {
  481. margin-right: @line-height-computed / 4;
  482. padding: 0;
  483. vertical-align: inherit;
  484. white-space: normal;
  485. text-align: left;
  486. }
  487. .v1-badge {
  488. margin-left: -4px;
  489. }
  490. .action-btn {
  491. padding: 0 0.3em;
  492. margin-left: 0.2em;
  493. }
  494. }
  495. i.tablesort {
  496. padding-left: 8px;
  497. }
  498. }
  499. .tag-label {
  500. margin-left: @line-height-computed / 4;
  501. position: relative;
  502. display: inline-block;
  503. white-space: nowrap;
  504. top: @tag-top-adjustment;
  505. }
  506. // Extra specificity needed to override Bootstrap's own specificity.
  507. .label.tag-label-name,
  508. .label.tag-label-remove {
  509. display: inline-block;
  510. padding: 3px 4px;
  511. border-radius: @tag-border-radius;
  512. background-color: @tag-bg-color;
  513. color: @tag-color;
  514. vertical-align: text-bottom;
  515. border-width: 0;
  516. &:hover,
  517. &:focus {
  518. color: @tag-color;
  519. background-color: @tag-bg-hover-color;
  520. outline-width: 0;
  521. }
  522. }
  523. .label.tag-label-name {
  524. padding-right: 2px;
  525. border-top-right-radius: 0;
  526. border-bottom-right-radius: 0;
  527. max-width: @tag-max-width;
  528. overflow: hidden;
  529. text-overflow: ellipsis;
  530. > .fa {
  531. margin-right: 0.3em;
  532. }
  533. }
  534. .label.tag-label-remove {
  535. padding-left: 2px;
  536. border-top-left-radius: 0;
  537. border-bottom-left-radius: 0;
  538. }
  539. .user_details_auto_complete {
  540. ul > li {
  541. list-style: none;
  542. }
  543. .autocomplete {
  544. width: 100%;
  545. position: relative;
  546. }
  547. .autocomplete ul {
  548. position: absolute;
  549. top: 100%;
  550. left: 0;
  551. z-index: @zindex-dropdown;
  552. float: left;
  553. min-width: 160px;
  554. padding: 5px 0;
  555. margin: 2px 0 0; // override default ul
  556. list-style: none;
  557. font-size: @font-size-base;
  558. background-color: @dropdown-bg;
  559. border: 1px solid @dropdown-fallback-border; // IE8 fallback
  560. border: 1px solid @dropdown-border;
  561. border-radius: @border-radius-base;
  562. .box-shadow(0 6px 12px rgba(0, 0, 0, 0.175));
  563. background-clip: padding-box;
  564. // Links within the dropdown menu
  565. > li {
  566. display: block;
  567. padding: 3px 20px;
  568. clear: both;
  569. font-weight: normal;
  570. line-height: @line-height-base;
  571. color: @dropdown-link-color;
  572. white-space: nowrap; // prevent links from randomly breaking onto new lines
  573. }
  574. > li.active {
  575. text-decoration: none;
  576. color: @dropdown-link-hover-color;
  577. background-color: @dropdown-link-hover-bg;
  578. }
  579. }
  580. .autocomplete .highlight {
  581. font-weight: 700;
  582. }
  583. }
  584. .minimal-create-proj-dropdown {
  585. text-align: center;
  586. &-menu {
  587. width: 200px;
  588. left: 50%;
  589. margin-left: -100px;
  590. }
  591. }
  592. .announcements {
  593. position: absolute;
  594. bottom: @footer-height;
  595. right: 0;
  596. height: 150px;
  597. width: 100%;
  598. pointer-events: none;
  599. overflow: hidden;
  600. &-open {
  601. top: -100%;
  602. height: auto;
  603. pointer-events: all;
  604. }
  605. }
  606. .announcements-backdrop {
  607. position: fixed;
  608. top: 0;
  609. right: 0;
  610. bottom: 0;
  611. left: 0;
  612. background-color: rgba(0, 0, 0, 0.35);
  613. opacity: 0;
  614. animation: fade-in 0.35s forwards;
  615. z-index: 1;
  616. }
  617. .announcements-btn {
  618. position: absolute;
  619. bottom: -35px;
  620. right: 3%;
  621. width: 80px;
  622. height: 80px;
  623. background: url(/img/brand/lion.svg) no-repeat center/80% transparent;
  624. border-radius: 50%;
  625. box-shadow: none;
  626. z-index: 1;
  627. pointer-events: all;
  628. transition: bottom 0.25s cubic-bezier(0.68, -0.55, 0.265, 1.55),
  629. background 0.25s ease, box-shadow 0.25s ease;
  630. &:hover {
  631. bottom: -25px;
  632. }
  633. &-open,
  634. &-open:hover,
  635. &-has-new,
  636. &-has-new:hover {
  637. background-color: #fff;
  638. box-shadow: @announcements-shadow;
  639. bottom: 30px;
  640. }
  641. }
  642. .announcements-badge {
  643. display: inline-block;
  644. position: absolute;
  645. font-size: 11px;
  646. height: 1.8em;
  647. min-width: 1.8em;
  648. border-radius: 0.9em;
  649. line-height: 1.8;
  650. padding: 0 2px;
  651. top: 1px;
  652. right: 1px;
  653. font-weight: bold;
  654. color: #fff;
  655. background-color: @red;
  656. vertical-align: baseline;
  657. white-space: nowrap;
  658. text-align: center;
  659. z-index: 1;
  660. animation: pulse 1s alternate infinite;
  661. }
  662. .announcements-body {
  663. display: flex;
  664. flex-direction: column;
  665. align-items: stretch;
  666. position: absolute;
  667. right: 3%;
  668. margin-right: 95px;
  669. bottom: 30px;
  670. width: 700px;
  671. max-height: 40%;
  672. min-height: 100px;
  673. background: #fff;
  674. z-index: 1;
  675. box-shadow: @announcements-shadow;
  676. border-radius: @border-radius-base;
  677. animation: fade-in 0.35s forwards;
  678. &::after {
  679. content: '\25b8';
  680. position: absolute;
  681. left: 100%;
  682. bottom: 17px;
  683. width: 30px;
  684. color: #fff;
  685. text-shadow: @announcements-shadow;
  686. font-size: 2em;
  687. overflow: hidden;
  688. text-indent: -7px;
  689. }
  690. }
  691. .announcements-scroller {
  692. padding: @line-height-computed;
  693. flex-grow: 0;
  694. overflow-x: hidden;
  695. overflow-y: auto;
  696. }
  697. .announcement {
  698. margin-bottom: @line-height-computed * 1.5;
  699. &:last-child {
  700. margin-bottom: 0;
  701. }
  702. }
  703. .announcement-header {
  704. .page-header;
  705. margin: 0;
  706. }
  707. .announcement-description {
  708. margin: (@line-height-computed / 4) 0 (@line-height-computed / 2);
  709. }
  710. .announcement-meta {
  711. .clearfix;
  712. font-size: 0.9em;
  713. }
  714. .announcement-date {
  715. float: left;
  716. color: @gray;
  717. margin: 0;
  718. }
  719. .announcement-link {
  720. float: right;
  721. margin: 0;
  722. }