style-editor.scss 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899900901902903904905906907908909910911912913914915916917918919920921922923924925926927928929930931932933934935936937938939940941942943944945946947948
  1. /*!
  2. Twenty Nineteen Editor Styles
  3. */
  4. /** === Includes === */
  5. @import "sass/variables-site/variables-site";
  6. @import "sass/mixins/mixins-master";
  7. /** === Editor Frame === */
  8. body {
  9. .wp-block[data-align="full"] {
  10. width: 100%;
  11. }
  12. @include media(mobile) {
  13. .wp-block[data-align="full"] {
  14. width: calc( 100% + 90px );
  15. max-width: calc( 100% + 90px );
  16. }
  17. }
  18. @include media(tablet) {
  19. .editor-writing-flow {
  20. max-width: 80%;
  21. margin: 0 10%;
  22. }
  23. .editor-post-title__block,
  24. .editor-default-block-appender,
  25. .editor-block-list__block {
  26. margin-left: 0;
  27. margin-right: 0;
  28. }
  29. .wp-block[data-align="wide"] {
  30. width: 100%;
  31. }
  32. .wp-block[data-align="full"] {
  33. position: relative;
  34. left: calc( -12.5% - 14px );
  35. width: calc( 125% + 116px );
  36. max-width: calc( 125% + 115px ); // Subtract 1px here to avoid the rounding errors that happen due to the usage of percentages.
  37. }
  38. .wp-block[data-align="right"] {
  39. max-width: 125%;
  40. }
  41. }
  42. }
  43. /** === Content Width === */
  44. .wp-block {
  45. width: calc(100vw - (2 * #{$size__spacing-unit}));
  46. max-width: 100%;
  47. @include media(tablet) {
  48. width: calc(8 * (100vw / 12));
  49. }
  50. @include media(desktop) {
  51. width: calc(6 * (100vw / 12 ));
  52. }
  53. // Only the top level blocks need specific widths, therefore override for every nested block.
  54. .wp-block {
  55. width: 100%;
  56. }
  57. }
  58. /** === Base Typography === */
  59. body {
  60. font-size: $font__size_base;
  61. @include font-family( $font__body );
  62. line-height: $font__line-height-body;
  63. color: $color__text-main;
  64. }
  65. p {
  66. font-size: $font__size_base;
  67. }
  68. h1,
  69. h2,
  70. h3,
  71. h4,
  72. h5,
  73. h6 {
  74. @include font-family( $font__heading );
  75. font-weight: 700;
  76. }
  77. h1 {
  78. font-size: $font__size-xl;
  79. @include post-section-dash;
  80. @include media(tablet) {
  81. font-size: $font__size-xxl;
  82. }
  83. }
  84. h2 {
  85. font-size: $font__size-lg;
  86. @include post-section-dash;
  87. @include media(tablet) {
  88. font-size: $font__size-xl;
  89. }
  90. }
  91. h3 {
  92. font-size: $font__size-lg;
  93. }
  94. h4 {
  95. font-size: $font__size-md;
  96. }
  97. h5 {
  98. font-size: $font__size-sm;
  99. }
  100. h6 {
  101. font-size: $font__size-xs;
  102. }
  103. a {
  104. @include link-transition;
  105. color: $color__link;
  106. *:visited {
  107. }
  108. &:hover,
  109. &:active {
  110. color: $color__link-hover;
  111. outline: 0;
  112. text-decoration: none;
  113. }
  114. &:focus {
  115. outline: 0;
  116. text-decoration: underline;
  117. }
  118. }
  119. // Use white text against these backgrounds by default.
  120. .has-primary-background-color,
  121. .has-secondary-background-color,
  122. .has-dark-gray-background-color,
  123. .has-light-gray-background-color {
  124. color: $color__background-body;
  125. p,
  126. h1,
  127. h2,
  128. h3,
  129. h4,
  130. h5,
  131. h6,
  132. a {
  133. color: $color__background-body;
  134. }
  135. }
  136. // Use dark gray text against this background by default.
  137. .has-white-background-color {
  138. color: $color__text-main;
  139. p,
  140. h1,
  141. h2,
  142. h3,
  143. h4,
  144. h5,
  145. h6,
  146. a {
  147. color: $color__text-main;
  148. }
  149. }
  150. figcaption,
  151. .gallery-caption {
  152. @include font-family( $font__heading );
  153. font-size: $font__size-xs;
  154. line-height: 1.6;
  155. color: $color__text-light;
  156. }
  157. /** === Post Title === */
  158. .editor-post-title__block {
  159. @include post-section-dash;
  160. &:before {
  161. width: $font__size-xxl;
  162. margin-top: 0;
  163. margin-bottom: 0;
  164. margin-left: 1em;
  165. position: relative;
  166. top: 0.5em;
  167. }
  168. .editor-post-title__input {
  169. @include font-family( $font__heading );
  170. font-size: $font__size-xxl;
  171. font-weight: 700;
  172. }
  173. }
  174. /** === Default Appender === */
  175. .editor-default-block-appender .editor-default-block-appender__content {
  176. @include font-family( $font__body );
  177. font-size: $font__size_base;
  178. }
  179. /** === Heading === */
  180. .wp-block-heading {
  181. strong {
  182. font-weight: bolder;
  183. }
  184. }
  185. /** === Paragraph === */
  186. .wp-block-paragraph {
  187. &.has-drop-cap:not(:focus)::first-letter {
  188. @include font-family( $font__heading );
  189. font-size: $font__size-xxxl;
  190. line-height: 1;
  191. font-weight: bold;
  192. margin: 0 0.25em 0 0;
  193. }
  194. }
  195. /** === Table === */
  196. .wp-block-table {
  197. @include font-family( $font__heading );
  198. }
  199. /** === Cover === */
  200. .wp-block-cover {
  201. h2,
  202. .wp-block-cover-text {
  203. @include font-family( $font__heading );
  204. font-size: $font__size-lg;
  205. font-weight: bold;
  206. line-height: 1.4;
  207. padding-left: $size__spacing-unit;
  208. padding-right: $size__spacing-unit;
  209. strong {
  210. font-weight: bolder;
  211. }
  212. @include media(tablet) {
  213. margin-left: auto;
  214. margin-right: auto;
  215. padding: 0;
  216. }
  217. }
  218. @include media(tablet) {
  219. padding-left: 10%;
  220. padding-right: 10%;
  221. h2,
  222. .wp-block-cover-text {
  223. font-size: $font__size-xl;
  224. }
  225. }
  226. }
  227. .wp-block[data-type="core/cover"][data-align="left"],
  228. .wp-block[data-type="core/cover"][data-align="right"] {
  229. .editor-block-list__block-edit {
  230. width: calc(4 * (100vw / 12));
  231. }
  232. .wp-block-cover {
  233. width: 100%;
  234. max-width: 100%;
  235. padding: calc(1.375 * #{$size__spacing-unit});
  236. p {
  237. padding-left: 0;
  238. padding-right: 0;
  239. }
  240. @include media(tablet) {
  241. padding: calc(2.75 * #{$size__spacing-unit}) calc(2.75 * #{$size__spacing-unit}) calc(3.125 * #{$size__spacing-unit});
  242. }
  243. }
  244. }
  245. .wp-block[data-type="core/cover"][data-align="wide"],
  246. .wp-block[data-type="core/cover"][data-align="full"] {
  247. @include media(tablet) {
  248. h2,
  249. .wp-block-cover-text {
  250. max-width: calc(8 * (100vw / 12));
  251. }
  252. }
  253. @include media(desktop) {
  254. h2,
  255. .wp-block-cover-text {
  256. max-width: calc(6 * (100vw / 12));
  257. }
  258. }
  259. }
  260. .wp-block[data-type="core/cover"][data-align="full"] {
  261. @include media(tablet) {
  262. .wp-block-cover {
  263. padding-left: calc(10% + 64px);
  264. padding-right: calc(10% + 64px);
  265. }
  266. }
  267. }
  268. /** === Gallery === */
  269. .wp-block-gallery {
  270. .blocks-gallery-image figcaption,
  271. .blocks-gallery-item figcaption,
  272. .gallery-item .gallery-caption {
  273. font-size: $font__size-xs;
  274. line-height: 1.6;
  275. }
  276. }
  277. /** === Button === */
  278. .wp-block-button {
  279. .wp-block-button__link {
  280. line-height: 1.8;
  281. @include font-family( $font__heading );
  282. font-size: $font__size-sm;
  283. font-weight: bold;
  284. }
  285. &:not(.is-style-outline) .wp-block-button__link {
  286. background: $color__background-button;
  287. }
  288. &:not(.is-style-squared) .wp-block-button__link {
  289. border-radius: 5px;
  290. }
  291. &.is-style-outline,
  292. &.is-style-outline:hover,
  293. &.is-style-outline:focus,
  294. &.is-style-outline:active {
  295. background: transparent;
  296. color: $color__background-button;
  297. .wp-block-button__link {
  298. background: transparent;
  299. &:not(.has-text-color) {
  300. color: $color__background-button;
  301. }
  302. }
  303. }
  304. }
  305. /** === Blockquote === */
  306. .wp-block-quote {
  307. &:not(.is-large):not(.is-style-large) {
  308. border-width: 2px;
  309. border-color: $color__link;
  310. }
  311. &.is-large,
  312. &.is-style-large {
  313. margin-top: $font__size-xxl;
  314. margin-bottom: $font__size-xxl;
  315. }
  316. &.is-large p,
  317. &.is-style-large p {
  318. font-size: $font__size-lg;
  319. line-height: 1.3;
  320. margin-bottom: 0.5em;
  321. margin-top: 0.5em;
  322. }
  323. cite,
  324. footer,
  325. .wp-block-quote__citation {
  326. @include font-family( $font__heading );
  327. font-size: $font__size-xs;
  328. line-height: 1.6;
  329. color: $color__text-light;
  330. }
  331. }
  332. /** === Pullquote === */
  333. .wp-block-pullquote {
  334. border-color: transparent;
  335. border-width: 2px;
  336. color: #000;
  337. blockquote {
  338. margin-top: calc(3 * #{ $size__spacing-unit});
  339. margin-bottom: calc(3.33 * #{ $size__spacing-unit});
  340. hyphens: auto;
  341. word-break: break-word;
  342. }
  343. &:not(.is-style-solid-color) .wp-block-pullquote__citation {
  344. color: $color__text-light;
  345. }
  346. &.is-style-solid-color {
  347. blockquote {
  348. width: calc(100% - (2 * #{ $size__spacing-unit}));
  349. max-width: calc( 100% - (2 * #{ $size__spacing-unit}));
  350. a,
  351. &.has-text-color p,
  352. &.has-text-color a {
  353. color: inherit;
  354. }
  355. &:not(.has-text-color) {
  356. color: $color__background-body;
  357. }
  358. @include media(tablet) {
  359. max-width: 80%;
  360. }
  361. }
  362. &:not(.has-background-color) {
  363. background-color: $color__link;
  364. }
  365. }
  366. }
  367. .wp-block[data-type="core/pullquote"],
  368. .wp-block[data-type="core/pullquote"][data-align="left"],
  369. .wp-block[data-type="core/pullquote"][data-align="right"] {
  370. blockquote > .block-library-pullquote__content .editor-rich-text__tinymce[data-is-empty="true"]::before,
  371. blockquote > .editor-rich-text p,
  372. p {
  373. font-size: $font__size-lg;
  374. font-style: italic;
  375. line-height: 1.3;
  376. margin-bottom: 0.5em;
  377. margin-top: 0.5em;
  378. @include media(tablet) {
  379. font-size: $font__size-xl;
  380. }
  381. }
  382. .wp-block-pullquote__citation {
  383. @include font-family( $font__heading );
  384. font-size: $font__size-xs;
  385. line-height: 1.6;
  386. text-transform: none;
  387. }
  388. em {
  389. font-style: normal;
  390. }
  391. }
  392. .wp-block[data-type="core/pullquote"][data-align="left"],
  393. .wp-block[data-type="core/pullquote"][data-align="right"] {
  394. .editor-block-list__block-edit {
  395. width: calc(4 * (100vw / 12));
  396. max-width: 50%;
  397. .wp-block-pullquote:not(.is-style-solid-color) {
  398. padding: 0;
  399. }
  400. .wp-block-pullquote.is-style-solid-color {
  401. padding: 1em;
  402. }
  403. }
  404. blockquote > .block-library-pullquote__content .editor-rich-text__tinymce[data-is-empty="true"]::before,
  405. blockquote > .editor-rich-text p,
  406. p,
  407. .wp-block-pullquote__citation {
  408. text-align: left;
  409. }
  410. }
  411. .wp-block[data-type="core/pullquote"][data-align="full"] {
  412. @include media(tablet) {
  413. .wp-block-pullquote blockquote {
  414. max-width: calc(80% - 128px);
  415. }
  416. }
  417. }
  418. /** === File === */
  419. .wp-block-file {
  420. @include font-family( $font__heading );
  421. .wp-block-file__textlink {
  422. text-decoration: underline;
  423. color: $color__link;
  424. &:hover {
  425. color: $color__link-hover;
  426. text-decoration: none;
  427. }
  428. }
  429. .wp-block-file__button {
  430. display: table;
  431. line-height: 1.8;
  432. font-size: $font__size-sm;
  433. font-weight: bold;
  434. background-color: $color__link;
  435. border-radius: 5px;
  436. }
  437. .wp-block-file__button-richtext-wrapper {
  438. display: block;
  439. margin-top: calc(0.75 * #{$size__spacing-unit});
  440. margin-left: 0;
  441. }
  442. }
  443. /** === Verse === */
  444. .wp-block-verse,
  445. .wp-block-verse pre {
  446. padding: 0;
  447. }
  448. /** === Code === */
  449. .wp-block-code {
  450. border-radius: 0;
  451. }
  452. /** === Table === */
  453. .wp-block-table {
  454. td, th {
  455. border-color: $color__text-light;
  456. }
  457. }
  458. /** === Separator === */
  459. .wp-block-separator {
  460. &:not(.is-style-dots) {
  461. background-color: $color__text-light;
  462. height: 2px;
  463. }
  464. &:not(.is-style-wide):not(.is-style-dots) {
  465. width: $font__size-xl;
  466. margin-left: 0;
  467. }
  468. &.is-style-dots {
  469. color: $color__text-light;
  470. }
  471. &.is-style-dots:before {
  472. font-size: $font__size-lg;
  473. letter-spacing: calc(2 * #{$size__spacing-unit});
  474. padding-left: calc(2 * #{$size__spacing-unit});
  475. }
  476. }
  477. /* Remove duplicate rule-line when a separator
  478. * is followed by an H1, or H2 */
  479. .wp-block[data-type="core/separator"] + .wp-block[data-type="core/heading"] h1:before,
  480. .wp-block[data-type="core/separator"] + .wp-block[data-type="core/heading"] h2:before {
  481. display: none;
  482. }
  483. /** === Latest Posts, Archives, Categories === */
  484. ul.wp-block-archives,
  485. .wp-block-categories,
  486. .wp-block-latest-posts {
  487. padding: 0;
  488. list-style-type: none;
  489. ul {
  490. padding: 0;
  491. list-style-type: none;
  492. }
  493. li {
  494. > a {
  495. @include font-family( $font__heading );
  496. font-size: calc(#{$font__size_base} * #{$font__size-ratio});
  497. font-weight: bold;
  498. line-height: $font__line-height-heading;
  499. text-decoration: none;
  500. }
  501. ul {
  502. padding-left: $size__spacing-unit;
  503. }
  504. }
  505. }
  506. .wp-block-categories {
  507. ul {
  508. padding-top: ( .75 * $size__spacing-unit );
  509. @include nestedSubMenuPadding();
  510. }
  511. li ul {
  512. list-style: none;
  513. padding-left: 0;
  514. margin-bottom: ( -.75 * $size__spacing-unit );
  515. }
  516. }
  517. /** === Latest Posts === */
  518. .wp-block-latest-posts {
  519. .wp-block-latest-posts__post-date {
  520. @include font-family( $font__heading );
  521. font-size: $font__size-xs;
  522. color: $color__text-light;
  523. line-height: 1.2;
  524. }
  525. .wp-block-latest-posts__post-full-content,
  526. .wp-block-latest-posts__post-excerpt {
  527. margin-top: $font__size_base;
  528. margin-bottom: $font__size_base;
  529. > div > p:first-child {
  530. margin-top: $font__size_base;
  531. }
  532. }
  533. li {
  534. padding-bottom: ( .5 * $size__spacing-unit );
  535. &.menu-item-has-children,
  536. &:last-child {
  537. padding-bottom: 0;
  538. }
  539. :not(:last-child) .wp-block-latest-posts__post-excerpt {
  540. padding-bottom: ( .5 * $size__spacing-unit );
  541. }
  542. }
  543. &.is-grid {
  544. li {
  545. border-top: 2px solid $color__border;
  546. padding-top: (1 * $size__spacing-unit);
  547. margin-bottom: (2 * $size__spacing-unit);
  548. a {
  549. &:after {
  550. content: '';
  551. }
  552. }
  553. &:last-child {
  554. margin-bottom: auto;
  555. a:after {
  556. content: '';
  557. }
  558. }
  559. }
  560. }
  561. }
  562. /** === Latest Comments === */
  563. .wp-block-latest-comments {
  564. .wp-block-latest-comments__comment-meta {
  565. @include font-family( $font__heading );
  566. font-weight: bold;
  567. .wp-block-latest-comments__comment-date {
  568. font-weight: normal;
  569. }
  570. }
  571. .wp-block-latest-comments__comment,
  572. .wp-block-latest-comments__comment-date,
  573. .wp-block-latest-comments__comment-excerpt p {
  574. font-size: inherit;
  575. }
  576. .wp-block-latest-comments__comment-date {
  577. font-size: $font__size-xs;
  578. }
  579. }
  580. /** === Classic Editor === */
  581. /* Properly center-align captions in the classic-editor block */
  582. .wp-caption {
  583. dd {
  584. color: $color__text-light;
  585. font-size: $font__size-xs;
  586. @include font-family( $font__heading );
  587. line-height: $font__line-height-pre;
  588. margin: 0;
  589. padding: ( $size__spacing-unit * .5 );
  590. text-align: left;
  591. text-align: center;
  592. -webkit-margin-start: 0px;
  593. margin-inline-start: 0px;
  594. }
  595. }
  596. .wp-block-freeform {
  597. /* Add style for galleries in classic-editor block */
  598. blockquote {
  599. border-left: 2px solid $color__link;
  600. cite {
  601. @include font-family( $font__heading );
  602. font-size: $font__size-xs;
  603. font-style: normal;
  604. line-height: 1.6;
  605. color: $color__text-light;
  606. }
  607. }
  608. }
  609. /** === Group Block === */
  610. // This matches the 22px value for 1rem that used on the front end.
  611. // It must be specified in pixels for the editor, since the root font
  612. // size is different here.
  613. $group-block-background__padding: $font__size_base;
  614. .wp-block[data-type="core/group"] {
  615. // Group block base styles
  616. > .editor-block-list__block-edit > div > .wp-block-group {
  617. // Child: Full alignment
  618. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout > .wp-block[data-align="full"] {
  619. left: 0;
  620. }
  621. }
  622. // Group block with background color
  623. > .editor-block-list__block-edit > div > .wp-block-group.has-background {
  624. padding: $group-block-background__padding;
  625. // Child: Full alignment
  626. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout > .wp-block[data-align="full"] {
  627. margin-left: -$group-block-background__padding;
  628. width: calc(100% + #{$group-block-background__padding * 2});
  629. max-width: calc(100% + #{$group-block-background__padding * 2});
  630. }
  631. }
  632. // Wide and full alignments
  633. &[data-align="wide"] {
  634. // Group block base styles.
  635. > .editor-block-list__block-edit > div > .wp-block-group {
  636. // Child blocks: Default alignments
  637. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout > .wp-block:not([data-align="wide"]):not([data-align="full"]) {
  638. @include media(tablet) {
  639. width: calc(8 * (100vw / 12));
  640. }
  641. @include media(desktop) {
  642. width: calc(6 * (100vw / 12 ));
  643. }
  644. }
  645. }
  646. // Group block with background color
  647. > .editor-block-list__block-edit > div > .wp-block-group.has-background {
  648. // Child blocks: Default alignments
  649. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout > .wp-block:not([data-align="wide"]):not([data-align="full"]) {
  650. @include media(tablet) {
  651. width: calc(8 * (100vw / 12) - #{$group-block-background__padding * 2});
  652. }
  653. @include media(desktop) {
  654. width: calc(6 * (100vw / 12 ) - #{$group-block-background__padding * 2});
  655. }
  656. }
  657. }
  658. }
  659. // Full alignment
  660. &[data-align="full"] {
  661. // Max-width needs to be a pixel narrower than usual to prevent horizontal scrolling.
  662. @include media(mobile) {
  663. max-width: calc(100% + 89px);
  664. }
  665. @include media(tablet) {
  666. max-width: calc(125% + 114px);
  667. }
  668. // Group block base styles
  669. > .editor-block-list__block-edit > div > .wp-block-group {
  670. // Margins & padding are added to this container to mimic
  671. // the style + spacing of the .editor-writing-flow global
  672. // container. This way, child items sync up with the placement
  673. // and size of other top-level blocks.
  674. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout {
  675. @include media(mobile) {
  676. padding-left: 46px;
  677. padding-right: 46px;
  678. }
  679. // 2px of extra padding are added to each side here
  680. // To better match up with the spacing of the whole
  681. // document.
  682. @include media(tablet) {
  683. width: 80%;
  684. margin-left: 10%;
  685. margin-right: 10%;
  686. padding-left: 48px;
  687. padding-right: 48px;
  688. }
  689. // Child blocks: All alignments except full
  690. > .wp-block:not([data-align="full"]) {
  691. max-width: calc(100vw - (2 * 1rem));
  692. @include media(tablet) {
  693. max-width: calc(8 * (100vw / 12));
  694. }
  695. @include media(desktop) {
  696. max-width: calc(6 * (100vw / 12));
  697. }
  698. }
  699. // Child blocks: Right alignments
  700. > .wp-block[data-align="right"] {
  701. @include media(tablet) {
  702. max-width: 125%;
  703. }
  704. }
  705. // Child blocks: Wide alignments
  706. > .wp-block[data-align="wide"] {
  707. @include media(tablet) {
  708. width: calc(100% + 4px);
  709. max-width: calc(100% + 4px);
  710. }
  711. }
  712. // Child blocks: Full alignments
  713. > .wp-block[data-align=full] {
  714. max-width: calc(100vw + (2 * 1rem));
  715. @include media(mobile) {
  716. width: calc(100% + 92px);
  717. left: -46px;
  718. }
  719. @include media(tablet) {
  720. left: calc(-12.5% - 58px);
  721. width: calc(125% + 120px);
  722. max-width: calc(125% + 119px);
  723. }
  724. }
  725. }
  726. }
  727. // Group block with background color
  728. > .editor-block-list__block-edit > div > .wp-block-group.has-background {
  729. // When the Group block is full width, we can remove the left/right padding
  730. // and let this inherit the
  731. padding: $group-block-background__padding 0;
  732. @include media(mobile) {
  733. padding-left: 0;
  734. padding-right: 0;
  735. }
  736. // Child blocks: Full alignment
  737. > .wp-block-group__inner-container > .editor-inner-blocks > .editor-block-list__layout > .wp-block[data-align="full"] {
  738. margin-left: 0;
  739. width: 100%;
  740. @include media(mobile) {
  741. width: calc(100% + 92px);
  742. }
  743. @include media(tablet) {
  744. width: calc(125% + 120px);
  745. }
  746. }
  747. }
  748. }
  749. }