variables.css 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163
  1. /*-----------------------------------------------------------------------------
  2. | Copyright (c) Jupyter Development Team.
  3. | Distributed under the terms of the Modified BSD License.
  4. |----------------------------------------------------------------------------*/
  5. /*
  6. The following CSS variables define the main, public API for styling JupyterLab.
  7. These variables should be used by all plugins wherever possible. In other
  8. words, plugins should not define custom colors, sizes, etc unless absolutely
  9. necessary. This enables users to change the visual theme of JupyterLab
  10. by changing these variables.
  11. Many variables appear in an ordered sequence (0,1,2,3). These sequences
  12. are designed to work well together, so for example, `--jp-border-color1` should
  13. be used with `--jp-layout-color1`. The numbers have the following meanings:
  14. * 0: super-primary, reserved for special emphasis
  15. * 1: primary, most important under normal situations
  16. * 2: secondary, next most important under normal situations
  17. * 3: tertiary, next most important under normal situations
  18. Throughout JupyterLab, we are mostly following principles from Google's
  19. Material Design when selecting colors. We are not, however, following
  20. all of MD as it is not optimized for dense, information rich UIs.
  21. */
  22. :root {
  23. /* Borders
  24. The following variables, specify the visual styling of borders in JupyterLab.
  25. */
  26. --jp-border-width: 1px;
  27. --jp-border-color0: var(--md-grey-700);
  28. --jp-border-color1: var(--md-grey-500);
  29. --jp-border-color2: var(--md-grey-300);
  30. --jp-border-color3: var(--md-grey-100);
  31. /* UI Fonts
  32. The UI font CSS variables are used for the typography all of the JupyterLab
  33. user interface elements that are not directly user generated content.
  34. */
  35. --jp-ui-font-scale-factor: 1.2;
  36. --jp-ui-font-size0: calc(var(--jp-ui-font-size1)/var(--jp-ui-font-scale-factor));
  37. --jp-ui-font-size1: 13px; /* Base font size */
  38. --jp-ui-font-size2: calc(var(--jp-ui-font-size1)*var(--jp-ui-font-scale-factor));
  39. --jp-ui-font-size3: calc(var(--jp-ui-font-size2)*var(--jp-ui-font-scale-factor));
  40. --jp-ui-icon-font-size: 14px; /* Ensures px perfect FontAwesome icons */
  41. --jp-ui-font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
  42. /* Use these font colors against the corresponding main layout colors.
  43. In a light theme, these go from dark to light.
  44. */
  45. --jp-ui-font-color0: rgba(0,0,0,1.0);
  46. --jp-ui-font-color1: rgba(0,0,0,0.87);
  47. --jp-ui-font-color2: rgba(0,0,0,0.54);
  48. --jp-ui-font-color3: rgba(0,0,0,0.38);
  49. /* Use these against the brand/accent/warn/error colors.
  50. These will typically go from light to darker, in both a dark and light theme
  51. */
  52. --jp-inverse-ui-font-color0: rgba(255,255,255,1);
  53. --jp-inverse-ui-font-color1: rgba(255,255,255,1.0);
  54. --jp-inverse-ui-font-color2: rgba(255,255,255,0.7);
  55. --jp-inverse-ui-font-color3: rgba(255,255,255,0.5);
  56. /* Content Fonts
  57. Content font variables are used for typography of user generated content.
  58. */
  59. --jp-content-font-size: 13px;
  60. --jp-content-line-height: 1.5;
  61. --jp-content-font-color0: black;
  62. --jp-content-font-color1: black;
  63. --jp-content-font-color2: var(--md-grey-700);
  64. --jp-content-font-color3: var(--md-grey-500);
  65. --jp-ui-font-scale-factor: 1.2;
  66. --jp-ui-font-size0: calc(var(--jp-ui-font-size1)/var(--jp-ui-font-scale-factor));
  67. --jp-ui-font-size1: 13px; /* Base font size */
  68. --jp-ui-font-size2: calc(var(--jp-ui-font-size1)*var(--jp-ui-font-scale-factor));
  69. --jp-ui-font-size3: calc(var(--jp-ui-font-size2)*var(--jp-ui-font-scale-factor));
  70. --jp-code-font-size: 13px;
  71. --jp-code-line-height: 17px;
  72. --jp-code-padding: 5px;
  73. --jp-code-font-family: monospace;
  74. /* Layout
  75. The following are the main layout colors use in JupyterLab. In a light
  76. theme these would go from light to dark.
  77. */
  78. --jp-layout-color0: white;
  79. --jp-layout-color1: white;
  80. --jp-layout-color2: var(--md-grey-200);
  81. --jp-layout-color3: var(--md-grey-400);
  82. /* Brand/accent */
  83. --jp-brand-color0: var(--md-blue-700);
  84. --jp-brand-color1: var(--md-blue-500);
  85. --jp-brand-color2: var(--md-blue-300);
  86. --jp-brand-color3: var(--md-blue-100);
  87. --jp-accent-color0: var(--md-green-700);
  88. --jp-accent-color1: var(--md-green-500);
  89. --jp-accent-color2: var(--md-green-300);
  90. --jp-accent-color3: var(--md-green-100);
  91. /* State colors (warn, error, success, info) */
  92. --jp-warn-color0: var(--md-orange-700);
  93. --jp-warn-color1: var(--md-orange-500);
  94. --jp-warn-color2: var(--md-orange-300);
  95. --jp-warn-color3: var(--md-orange-100);
  96. --jp-error-color0: var(--md-red-700);
  97. --jp-error-color1: var(--md-red-500);
  98. --jp-error-color2: var(--md-red-300);
  99. --jp-error-color3: var(--md-red-100);
  100. --jp-success-color0: var(--md-green-700);
  101. --jp-success-color1: var(--md-green-500);
  102. --jp-success-color2: var(--md-green-300);
  103. --jp-success-color3: var(--md-green-100);
  104. --jp-info-color0: var(--md-cyan-700);
  105. --jp-info-color1: var(--md-cyan-500);
  106. --jp-info-color2: var(--md-cyan-300);
  107. --jp-info-color3: var(--md-cyan-100);
  108. /* Notebook specific styles */
  109. --jp-notebook-scroll-padding: 100px;
  110. /* The caret used for select dropdown styling. */
  111. --jp-ui-select-caret: url('./images/down_caret.svg');
  112. /* Icons used in the application. */
  113. --jp-icon-book-running: url('./icons/md/book_running.svg');
  114. --jp-icon-book-selected: url('./icons/md/book_selected.svg');
  115. --jp-icon-directory-selected: url('./icons/md/directory_selected.svg');
  116. --jp-icon-file-selected: url('./icons/md/file_selected.svg');
  117. --jp-icon-book: url('./icons/md/book.svg');
  118. --jp-icon-terminal: url('./icons/md/terminal.svg');
  119. --jp-icon-file: url('./icons/md/file.svg');
  120. --jp-icon-refresh: url('./icons/md/refresh.svg');
  121. --jp-icon-close: url('./icons/md/close.svg');
  122. --jp-icon-circle: url('./icons/md/circle.svg');
  123. --jp-icon-close-black: url('./icons/md/close-black.svg');
  124. --jp-icon-search: url('./icons/md/search.svg');
  125. }