repository.less 15 KB

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