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.
 
 
 
 

53 lines
1.6 KiB

  1. .highlight{
  2. font-size: rem-calc(14px);
  3. padding: 0;
  4. background-color: lighten($secondary-color, 8%);
  5. font-family: 'Source Code Pro', 'Consolas', Monaco, monospace;
  6. overflow: auto;
  7. margin-bottom: rem-calc(16px);
  8. pre{
  9. tab-size: 4;
  10. white-space: pre;
  11. font-family: inherit;
  12. counter-reset: line-numbering;
  13. border: solid 1px #d9d9d9;
  14. border-radius: 0;
  15. background: #fff;
  16. padding: rem-calc(3px);
  17. line-height: 23px;
  18. overflow-x: auto;
  19. word-break: inherit;
  20. word-wrap: inherit;
  21. a {
  22. &::before {
  23. content: counter(line-numbering);
  24. counter-increment: line-numbering;
  25. padding-right: 1em; /* space after numbers */
  26. width: 25px;
  27. text-align: right;
  28. opacity: 0.7;
  29. display: inline-block;
  30. color: #aaa;
  31. background: #eee;
  32. margin-right: 16px;
  33. padding: 2px 10px;
  34. -webkit-touch-callout: none;
  35. -webkit-user-select: none;
  36. -khtml-user-select: none;
  37. -moz-user-select: none;
  38. -ms-user-select: none;
  39. user-select: none;
  40. }
  41. &:first-of-type::before {
  42. padding-top: 10px;
  43. }
  44. &:last-of-type::before {
  45. padding-bottom: 10px;
  46. }
  47. &:only-of-type::before {
  48. padding: 10px;
  49. }
  50. }
  51. }
  52. }