You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

repository.less 16KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799
  1. @import "../ui/var";
  2. @repoHeaderBorderColor: #D6D6D6;
  3. @repoHeaderBgColor: #FFF;
  4. @repoHeaderNameColor: #888;
  5. #repo-wrapper {
  6. padding-bottom: 100px;
  7. }
  8. #repo-header {
  9. height: 69px;
  10. border-bottom: 1px solid@repoHeaderBorderColor;
  11. background-color: @repoHeaderBgColor;
  12. }
  13. #repo-header-name {
  14. line-height: 66px;
  15. color: @repoHeaderNameColor;
  16. font-size: 1.6em;
  17. font-weight: normal;
  18. margin-bottom: 0;
  19. i {
  20. margin-right: 12px;
  21. vertical-align: middle;
  22. }
  23. .divider {
  24. margin: 0 4px;
  25. }
  26. }
  27. #repo-header-meta {
  28. line-height: 66px;
  29. li {
  30. >a {
  31. padding: 0;
  32. &:hover {
  33. background-color: transparent;
  34. }
  35. }
  36. }
  37. a {
  38. &>.btn {
  39. line-height: 16px;
  40. margin-left: 16px;
  41. font-size: 13px;
  42. i {
  43. margin-right: 6px;
  44. }
  45. .num {
  46. margin-left: 6px;
  47. }
  48. }
  49. }
  50. }
  51. #repo-header-download-btn {
  52. >.btn>i {
  53. margin-right: 0 !important;
  54. }
  55. &:hover {
  56. &:after, .btn {
  57. background-color: @btnHoverBlackColor;
  58. color: #FFF;
  59. }
  60. }
  61. &:after {
  62. background-color: @btnBlackColor;
  63. padding: 9px 16px 8px 0;
  64. margin-left: -8px !important;
  65. color: #FFF;
  66. border-top: 1px solid@btnBlackColor;
  67. border-bottom: 1px solid@btnBlackColor;
  68. border-top-right-radius: .25em;
  69. border-bottom-right-radius: .25em;
  70. }
  71. }
  72. #repo-header-download-drop {
  73. line-height: 24px;
  74. width: 460px;
  75. top: 50px;
  76. left: -390px;
  77. padding: 20px;
  78. box-sizing: border-box;
  79. z-index: 1;
  80. .btn>i {
  81. margin-right: 6px;
  82. }
  83. input {
  84. cursor: default;
  85. }
  86. button, input {
  87. font-size: 11px;
  88. }
  89. #repo-clone-copy {
  90. width: 85px;
  91. text-overflow: clip;
  92. }
  93. }
  94. #repo-content {
  95. padding-top: 18px;
  96. padding-bottom: 18px;
  97. }
  98. .repo-wide-wrapper {
  99. padding: 18px;
  100. position: relative;
  101. }
  102. #repo-clone-url {
  103. border-right: none;
  104. width: 190px;
  105. border-left: none;
  106. }
  107. #repo-clone-help {
  108. clear: both;
  109. line-height: 48px;
  110. }
  111. #repo-clone-zip {
  112. line-height: 48px;
  113. a {
  114. cursor: pointer;
  115. color: white;
  116. overflow: visible;
  117. padding: .6em 1.2em;
  118. }
  119. .btn {
  120. margin: 0 6px;
  121. }
  122. }
  123. #repo-desc {
  124. font-size: 1.2em;
  125. .no-description{
  126. color: #999;
  127. }
  128. }
  129. #repo-sidebar-nav {
  130. .label {
  131. font-size: 12px;
  132. line-height: 1.4em;
  133. margin-top: 2px;
  134. }
  135. i {
  136. margin-right: 6px;
  137. }
  138. }
  139. #repo-sidebar-mini {
  140. margin-top: 6px;
  141. width: 60px;
  142. li {
  143. margin-bottom: 4px;
  144. }
  145. li > a {
  146. position: relative;
  147. padding-left: 12px;
  148. width: 24px;
  149. text-align: center;
  150. >i.octicon {
  151. font-size: 21px;
  152. }
  153. }
  154. .num {
  155. position: absolute;
  156. font-size: 12px;
  157. top: 0;
  158. left: 36px;
  159. padding: 0 2px;
  160. min-width: 16px;
  161. height: 16px;
  162. text-align: center;
  163. line-height: 16px;
  164. border-radius: 4px;
  165. opacity: 0.7;
  166. -webkit-transform: scale(0.9);
  167. font-weight: bold;
  168. }
  169. }
  170. #repo-file-nav {
  171. padding: .6em 0 1em 0;
  172. >li>a {
  173. padding-left: 0;
  174. &:hover {
  175. background-color: transparent;
  176. }
  177. }
  178. li.repo-jump > a {
  179. padding-right: 0;
  180. .btn {
  181. margin-left: -1px;
  182. }
  183. }
  184. }
  185. #repo-branch-switch {
  186. >a {
  187. .btn {
  188. padding-right: 30px;
  189. }
  190. &:after {
  191. position: absolute;
  192. top: 12px;
  193. right: 30px;
  194. margin-left: 0;
  195. color: @baseFontColor;
  196. }
  197. }
  198. >.drop-down {
  199. top: 40px;
  200. left: 0;
  201. }
  202. }
  203. #repo-branch-filter-ipt {
  204. width: 100%;
  205. border-left: none;
  206. border-right: none;
  207. box-sizing: border-box;
  208. }
  209. #repo-branch-tag {
  210. .tab-nav {
  211. border-bottom: 1px solid #EAEAEA;
  212. a {
  213. padding: .3em .8em;
  214. }
  215. .js-tab-nav-show {
  216. background-color: #EEE;
  217. font-weight: bold;
  218. }
  219. }
  220. .switching-list {
  221. max-height: 300px;
  222. overflow-y: auto;
  223. }
  224. }
  225. #repo-branch-list,
  226. #repo-tag-list {
  227. li {
  228. i {
  229. margin-right: 12px;
  230. opacity: 0;
  231. }
  232. }
  233. li.checked {
  234. i {
  235. opacity: 1;
  236. }
  237. }
  238. }
  239. #repo-bread {
  240. .bread {
  241. padding-right: 0;
  242. font-size: 16px;
  243. font-weight: bold;
  244. }
  245. }
  246. #repo-main {
  247. padding-right: 40px;
  248. box-sizing: border-box;
  249. }
  250. #repo-files-table {
  251. margin-bottom: 20px;
  252. .sha .label {
  253. font-family: Monaco,Menlo,Consolas,"Courier New",monospace;
  254. }
  255. th, td {
  256. text-align: left;
  257. line-height: 32px;
  258. }
  259. td.icon {
  260. width: 16px;
  261. padding-right: .1em;
  262. padding-left: 1em;
  263. }
  264. td.name {
  265. max-width: 120px;
  266. .text-truncate {
  267. max-width: 100%;
  268. }
  269. }
  270. td.age {
  271. max-width: 120px;
  272. text-align: right;
  273. }
  274. td.msg {
  275. max-width: 440px;
  276. .text-truncate {
  277. max-width: 100%;
  278. }
  279. }
  280. td.age,
  281. td.size,
  282. td.msg a {
  283. color: #888;
  284. }
  285. td.msg a:hover {
  286. color: #428BCA;
  287. text-decoration: underline;
  288. }
  289. td.message {
  290. .text-truncate {
  291. max-width: 360px;
  292. }
  293. }
  294. tbody {
  295. background-color: #FFF;
  296. tr:hover {
  297. background-color: #ffffEE;
  298. }
  299. }
  300. thead {
  301. background-color: #F0F0F0;
  302. .author {
  303. a {
  304. margin: 0 .4em;
  305. }
  306. }
  307. .last-commit {
  308. strong {
  309. color: #444;
  310. }
  311. .text-truncate {
  312. max-width: 440px;
  313. margin-left: .4em;
  314. }
  315. }
  316. .last-commit .text-truncate,
  317. .age {
  318. font-weight: normal;
  319. color: #888;
  320. }
  321. }
  322. }
  323. #repo-readme,
  324. #repo-read-file {
  325. margin-bottom: 80px;
  326. }
  327. #repo-bare-start {
  328. margin-bottom: 100px;
  329. .panel-content {
  330. background-color: #FFF;
  331. }
  332. pre {
  333. margin: 0 40px;
  334. padding: 6px 10px;
  335. border: 1px solid #ddd;
  336. background: #f8f8f8;
  337. }
  338. }
  339. .repo-bare {
  340. #repo-bare-start {
  341. h2 {
  342. margin-top: 30px;
  343. margin-bottom: 24px;
  344. }
  345. }
  346. #repo-header-meta {
  347. display: none;
  348. }
  349. #repo-clone-ssh {
  350. margin-left: 200px;
  351. }
  352. #repo-clone-copy {
  353. margin-right: 200px;
  354. }
  355. #repo-clone-help {
  356. clear: both;
  357. width: 100%;
  358. }
  359. #repo-clone-url {
  360. width: 520px;
  361. }
  362. }
  363. /* repository create */
  364. #team-create-form,
  365. #repo-migrate-form,
  366. #repo-create-form {
  367. width: 800px;
  368. margin: 60px auto auto auto;
  369. background: white;
  370. h2 {
  371. margin: .5em 1em;
  372. }
  373. .field {
  374. margin: 1.2em 0 2em 0;
  375. }
  376. .ipt {
  377. width: 540px;
  378. }
  379. textarea {
  380. height: 120px;
  381. }
  382. .avatar {
  383. vertical-align: middle;
  384. margin-right: .6em;
  385. width: 28px;
  386. height: 28px;
  387. }
  388. &:hover {
  389. box-shadow: 0px 0px 6px #CCC;
  390. }
  391. }
  392. #repo-create-cancel {
  393. margin-left: 4em;
  394. }
  395. #release-new-target-branch-list,
  396. #repo-create-owner-list {
  397. top: 30px;
  398. left: 0;
  399. width: auto;
  400. max-width: 300px;
  401. .octicon {
  402. margin-right: 12px;
  403. opacity: 0;
  404. }
  405. .avatar {
  406. width: 20px;
  407. height: 20px;
  408. }
  409. li {
  410. white-space: nowrap;
  411. &.checked {
  412. .octicon {
  413. opacity: 1;
  414. }
  415. }
  416. a {
  417. text-overflow: ellipsis;
  418. -o-text-overflow: ellipsis;
  419. overflow: hidden;
  420. }
  421. }
  422. }
  423. #release-new-target-branch-list {
  424. margin-top: -1px;
  425. min-width: 150px;
  426. }
  427. #release-new-title {
  428. margin-top: 10px;
  429. }
  430. #release-new-content {
  431. width: 100%;
  432. }
  433. #release-preview-btn .btn {
  434. border-left: 0;
  435. }
  436. #release-preview.markdown {
  437. margin-top: 5px;
  438. background-color: transparent;
  439. }
  440. .file-name {
  441. margin-left: 1em;
  442. }
  443. .file-size {
  444. font-size: 13px;
  445. color: #888;
  446. margin-left: 1em;
  447. }
  448. .code-view {
  449. overflow: auto;
  450. overflow-x: auto;
  451. overflow-y: hidden;
  452. background: white;
  453. .view-raw {
  454. min-height: 40px;
  455. text-align: center;
  456. padding-top: 20px;
  457. .btn {
  458. font-size: 1.05em;
  459. line-height: 16px;
  460. padding: 6px 8px;
  461. }
  462. }
  463. table {
  464. width: 100%;
  465. td {
  466. padding: 0;
  467. }
  468. }
  469. .lines-num {
  470. vertical-align: top;
  471. text-align: right;
  472. color: #999;
  473. background: #f5f5f5;
  474. width: 1%;
  475. span {
  476. font-family: Monaco,Menlo,Consolas,"Courier New",monospace;
  477. line-height: 20px;
  478. padding: 0 10px;
  479. cursor: pointer;
  480. display: block;
  481. }
  482. }
  483. .lines-code > pre {
  484. border: none;
  485. border-left: 1px solid #ddd;
  486. > ol.linenums > li {
  487. padding: 0 10px;
  488. line-height: 20px;
  489. &.active {
  490. background: #ffffdd;
  491. }
  492. }
  493. }
  494. }
  495. .repo-setting-zone {
  496. padding: 30px;
  497. }
  498. #team-repositories-list,
  499. #team-members-list,
  500. #repo-collab-list {
  501. list-style: none;
  502. padding: 10px 0 5px 0;
  503. li.collab {
  504. clear: both;
  505. height: 50px;
  506. padding: 0 15px 0 15px;
  507. }
  508. a.member {
  509. color: #444;
  510. height: 50px;
  511. line-height: 50px;
  512. &:hover {
  513. color: #4183C4;
  514. }
  515. }
  516. .avatar {
  517. margin-right: 1em;
  518. width: 40px;
  519. }
  520. .remove-collab {
  521. color: #DD4B39;
  522. }
  523. }
  524. .repo-user-list-block {
  525. position: relative;
  526. top: 5px;
  527. }
  528. .setting-list {
  529. width: 100%;
  530. list-style: none;
  531. }
  532. #commits-list {
  533. padding-top: 20px;
  534. h4{
  535. line-height: 30px;
  536. margin-bottom: 0;
  537. }
  538. }
  539. .commit-list {
  540. th {
  541. background-color: #FFF;
  542. line-height: 28px !important;
  543. }
  544. .date {
  545. width: 120px;
  546. }
  547. .author {
  548. padding-left: 20px;
  549. min-width: 180px;
  550. img {
  551. margin-top: -4px;
  552. }
  553. }
  554. .sha a {
  555. font-family: Consolas, Menlo, Monaco, "Lucida Console", monospace;
  556. font-size: 14px;
  557. }
  558. .message {
  559. width: 60%;
  560. span {
  561. max-width: 500px;
  562. }
  563. }
  564. }
  565. .commit-message {
  566. white-space: pre-wrap;
  567. }
  568. .diff-head-box {
  569. margin-top: 10px;
  570. .panel-body {
  571. padding: 10px 15px 5px 10px;
  572. }
  573. .author {
  574. img {
  575. margin-top: -7px;
  576. }
  577. }
  578. }
  579. .diff-detail-box {
  580. margin: 15px 0;
  581. line-height: 30px;
  582. ol {
  583. clear: both;
  584. padding-left: 0;
  585. margin-bottom: 28px;
  586. li {
  587. list-style: none;
  588. padding-bottom: 4px;
  589. margin-bottom: 4px;
  590. border-bottom: 1px dashed #DDD;
  591. padding-left: 6px;
  592. }
  593. }
  594. span.status{
  595. display: inline-block;
  596. width: 12px;
  597. height: 12px;
  598. margin-right: 8px;
  599. vertical-align: middle;
  600. &.modify {
  601. background-color: #f0db88;
  602. }
  603. &.add {
  604. background-color: #b4e2b4;
  605. }
  606. &.del {
  607. background-color: #e9aeae;
  608. }
  609. &.rename {
  610. background-color: #dad8ff;
  611. }
  612. }
  613. }
  614. .diff-box {
  615. .count {
  616. margin-right: 12px;
  617. .bar {
  618. background-color: #e75316;
  619. height: 12px;
  620. width: 40px;
  621. display: inline-block;
  622. margin: 2px 4px 0 4px;
  623. vertical-align: text-top;
  624. .add {
  625. background-color: #77c64a;
  626. height: 12px;
  627. }
  628. }
  629. }
  630. .file {
  631. color: #888;
  632. }
  633. .panel-header {
  634. font-size: 14px;
  635. }
  636. }
  637. .diff-file-box {
  638. .file-body.file-code {
  639. .lines-num {
  640. text-align: right;
  641. color: #999;
  642. background: #fafafa;
  643. width: 1%;
  644. }
  645. .lines-num-old {
  646. border-right: 1px solid #DDD;
  647. }
  648. }
  649. .code-diff {
  650. tbody {
  651. tr {
  652. &.tag-code {
  653. td, pre {
  654. background-color: #E0E0E0 !important;
  655. border-color: #ADADAD !important;
  656. }
  657. td.selected-line, td.selected-line pre {
  658. background-color: #ffffdd !important;
  659. }
  660. }
  661. &.same-code {
  662. td.selected-line, td.selected-line pre {
  663. background-color: #ffffdd !important;
  664. }
  665. }
  666. &.del-code {
  667. td, pre {
  668. background-color: #ffe2dd !important;
  669. border-color: #e9aeae !important;
  670. }
  671. td.selected-line, td.selected-line pre {
  672. background-color: #ffffdd !important;
  673. }
  674. }
  675. &.add-code {
  676. td, pre {
  677. background-color: #d1ffd6 !important;
  678. border-color: #b4e2b4 !important;
  679. }
  680. td.selected-line, td.selected-line pre {
  681. background-color: #ffffdd !important;
  682. }
  683. }
  684. &:hover {
  685. td, pre {
  686. background-color: #FFF8D2 !important;
  687. border-color: #F0DB88 !important;
  688. }
  689. }
  690. }
  691. }
  692. }
  693. }
  694. .compare-head-box {
  695. margin-top: 10px;
  696. .compare {
  697. padding: 0 15px 15px 15px;
  698. }
  699. }
  700. .fork-flag {
  701. display: block;
  702. font-size: 11px;
  703. line-height: 10px;
  704. white-space: nowrap;
  705. margin-left: 44px;
  706. margin-top: -15px;
  707. }
  708. #release {
  709. h4 {
  710. font-size: 18px;
  711. small {
  712. font-weight: 400;
  713. line-height: 1;
  714. color: #999;
  715. }
  716. }
  717. #release-head {
  718. margin-top: 0;
  719. margin-bottom: 0;
  720. padding-bottom: 20px;
  721. border-bottom: 1px solid #DDD;
  722. .btn {
  723. margin-left: 10px;
  724. }
  725. }
  726. .release-item {
  727. &>div {
  728. padding-top: 20px;
  729. padding-bottom: 20px;
  730. }
  731. .label-green:hover {
  732. background-color: @labelGreenColor;
  733. }
  734. .release-meta {
  735. position: relative;
  736. float: left;
  737. padding-right: 15px;
  738. }
  739. .tag,
  740. .commit {
  741. display: block;
  742. margin-top: 12px;
  743. line-height: 20px;
  744. }
  745. .release-detail {
  746. margin-top: -1px;
  747. border-left: 1px solid #DDD;
  748. position: relative;
  749. float: left;
  750. padding-left: 15px;
  751. }
  752. .title {
  753. line-height: 25px;
  754. margin-top: 0;
  755. }
  756. p.info {
  757. line-height: 20px;
  758. color: #666;
  759. margin-bottom: 15px;
  760. >* {
  761. margin-right: 10px;
  762. }
  763. }
  764. .author {
  765. img {
  766. margin-top: -3px;
  767. }
  768. }
  769. div.desc {
  770. margin-bottom: 25px;
  771. &.markdown {
  772. background-color: transparent;
  773. }
  774. }
  775. .download a {
  776. margin-right: 10px;
  777. }
  778. .dot {
  779. width: 9px;
  780. height: 9px;
  781. background-color: #ccc;
  782. z-index: 999;
  783. position: absolute;
  784. display: block;
  785. left: -6px;
  786. top: 27px;
  787. border-radius: 6px;
  788. border: 1px solid #FFF;
  789. }
  790. }
  791. #release-new-form {
  792. padding-top: 15px;
  793. }
  794. }