editor.css 5.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173
  1. /**
  2. * Colors
  3. */
  4. /**
  5. * Breakpoints & Media Queries
  6. */
  7. /**
  8. * SCSS Variables.
  9. *
  10. * Please use variables from this sheet to ensure consistency across the UI.
  11. * Don't add to this sheet unless you're pretty sure the value will be reused in many places.
  12. * For example, don't add rules to this sheet that affect block visuals. It's purely for UI.
  13. */
  14. /**
  15. * Colors
  16. */
  17. /**
  18. * Fonts & basic variables.
  19. */
  20. /**
  21. * Grid System.
  22. * https://make.wordpress.org/design/2019/10/31/proposal-a-consistent-spacing-system-for-wordpress/
  23. */
  24. /**
  25. * Dimensions.
  26. */
  27. /**
  28. * Shadows.
  29. */
  30. /**
  31. * Editor widths.
  32. */
  33. /**
  34. * Block & Editor UI.
  35. */
  36. /**
  37. * Block paddings.
  38. */
  39. /**
  40. * React Native specific.
  41. * These variables do not appear to be used anywhere else.
  42. */
  43. /**
  44. * Converts a hex value into the rgb equivalent.
  45. *
  46. * @param {string} hex - the hexadecimal value to convert
  47. * @return {string} comma separated rgb values
  48. */
  49. /**
  50. * Breakpoint mixins
  51. */
  52. /**
  53. * Long content fade mixin
  54. *
  55. * Creates a fading overlay to signify that the content is longer
  56. * than the space allows.
  57. */
  58. /**
  59. * Focus styles.
  60. */
  61. /**
  62. * Applies editor left position to the selector passed as argument
  63. */
  64. /**
  65. * Styles that are reused verbatim in a few places
  66. */
  67. /**
  68. * Allows users to opt-out of animations via OS-level preferences.
  69. */
  70. /**
  71. * Reset default styles for JavaScript UI based pages.
  72. * This is a WP-admin agnostic reset
  73. */
  74. /**
  75. * Reset the WP Admin page styles for Gutenberg-like pages.
  76. */
  77. .wp-block-post-featured-image .block-editor-media-placeholder {
  78. z-index: 1;
  79. -webkit-backdrop-filter: none;
  80. backdrop-filter: none;
  81. }
  82. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder,
  83. .wp-block-post-featured-image .components-placeholder {
  84. justify-content: center;
  85. align-items: center;
  86. padding: 0;
  87. min-height: 200px;
  88. }
  89. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder .components-form-file-upload,
  90. .wp-block-post-featured-image .components-placeholder .components-form-file-upload {
  91. display: none;
  92. }
  93. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder .components-button,
  94. .wp-block-post-featured-image .components-placeholder .components-button {
  95. padding: 0;
  96. display: flex;
  97. justify-content: center;
  98. align-items: center;
  99. width: 48px;
  100. height: 48px;
  101. border-radius: 50%;
  102. position: relative;
  103. background: var(--wp-admin-theme-color);
  104. border-color: var(--wp-admin-theme-color);
  105. border-style: solid;
  106. color: #fff;
  107. }
  108. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder .components-button > svg,
  109. .wp-block-post-featured-image .components-placeholder .components-button > svg {
  110. color: inherit;
  111. }
  112. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where(.has-border-color),
  113. .wp-block-post-featured-image .components-placeholder:where(.has-border-color),
  114. .wp-block-post-featured-image img:where(.has-border-color) {
  115. border-style: solid;
  116. }
  117. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-top-color"]),
  118. .wp-block-post-featured-image .components-placeholder:where([style*="border-top-color"]),
  119. .wp-block-post-featured-image img:where([style*="border-top-color"]) {
  120. border-top-style: solid;
  121. }
  122. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-right-color"]),
  123. .wp-block-post-featured-image .components-placeholder:where([style*="border-right-color"]),
  124. .wp-block-post-featured-image img:where([style*="border-right-color"]) {
  125. border-right-style: solid;
  126. }
  127. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-bottom-color"]),
  128. .wp-block-post-featured-image .components-placeholder:where([style*="border-bottom-color"]),
  129. .wp-block-post-featured-image img:where([style*="border-bottom-color"]) {
  130. border-bottom-style: solid;
  131. }
  132. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-left-color"]),
  133. .wp-block-post-featured-image .components-placeholder:where([style*="border-left-color"]),
  134. .wp-block-post-featured-image img:where([style*="border-left-color"]) {
  135. border-left-style: solid;
  136. }
  137. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-width"]),
  138. .wp-block-post-featured-image .components-placeholder:where([style*="border-width"]),
  139. .wp-block-post-featured-image img:where([style*="border-width"]) {
  140. border-style: solid;
  141. }
  142. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-top-width"]),
  143. .wp-block-post-featured-image .components-placeholder:where([style*="border-top-width"]),
  144. .wp-block-post-featured-image img:where([style*="border-top-width"]) {
  145. border-top-style: solid;
  146. }
  147. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-right-width"]),
  148. .wp-block-post-featured-image .components-placeholder:where([style*="border-right-width"]),
  149. .wp-block-post-featured-image img:where([style*="border-right-width"]) {
  150. border-right-style: solid;
  151. }
  152. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-bottom-width"]),
  153. .wp-block-post-featured-image .components-placeholder:where([style*="border-bottom-width"]),
  154. .wp-block-post-featured-image img:where([style*="border-bottom-width"]) {
  155. border-bottom-style: solid;
  156. }
  157. .wp-block-post-featured-image .wp-block-post-featured-image__placeholder:where([style*="border-left-width"]),
  158. .wp-block-post-featured-image .components-placeholder:where([style*="border-left-width"]),
  159. .wp-block-post-featured-image img:where([style*="border-left-width"]) {
  160. border-left-style: solid;
  161. }
  162. .wp-block-post-featured-image[style*=height] .components-placeholder {
  163. min-height: 48px;
  164. min-width: 48px;
  165. height: 100%;
  166. width: 100%;
  167. }
  168. div[data-type="core/post-featured-image"] img {
  169. max-width: 100%;
  170. height: auto;
  171. display: block;
  172. }