@cooperco/cooper-component-library 0.1.131 → 0.1.132
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/lib/css/main.css +42 -3
- package/dist/lib/style.css +1 -1
- package/package.json +1 -1
package/dist/lib/css/main.css
CHANGED
|
@@ -86,8 +86,8 @@ div {
|
|
|
86
86
|
padding-left: 1rem;
|
|
87
87
|
} */
|
|
88
88
|
|
|
89
|
-
/*
|
|
90
|
-
and shared across
|
|
89
|
+
/* Body Copy rich text styles (paragraph spacing + lists) live in
|
|
90
|
+
@layer components and are shared across Body Copy wrappers. */
|
|
91
91
|
|
|
92
92
|
.content-module-body-copy {
|
|
93
93
|
white-space: pre-line;
|
|
@@ -334,8 +334,47 @@ div {
|
|
|
334
334
|
transform: translateY(0);
|
|
335
335
|
}
|
|
336
336
|
|
|
337
|
-
/* ─── Unified
|
|
337
|
+
/* ─── Unified Body Copy rich text styles ─── */
|
|
338
338
|
@layer components {
|
|
339
|
+
/*
|
|
340
|
+
* Restore paragraph spacing for Contentful Body Copy HTML.
|
|
341
|
+
* Tailwind Preflight sets `p { margin: 0 }`. Scope to Body Copy
|
|
342
|
+
* wrappers only — do not use a global `p` rule.
|
|
343
|
+
*
|
|
344
|
+
* Space after non-last paragraphs / lists (not top-margin on every
|
|
345
|
+
* following sibling). Child combinators skip table-cell <p>s
|
|
346
|
+
* (`.content-module-body-copy table p { margin: 0 }` stays intact).
|
|
347
|
+
* `:not(:has(+ table))` avoids stacking with table { margin: 1rem 0 }.
|
|
348
|
+
* A lone paragraph is :last-child, so CTAs outside the wrapper are
|
|
349
|
+
* unaffected. Accordion v-html sits in an inner div.
|
|
350
|
+
*/
|
|
351
|
+
.content-module-body-copy > p:not(:last-child):not(:has(+ table)),
|
|
352
|
+
.body-copy-with-lists > p:not(:last-child):not(:has(+ table)),
|
|
353
|
+
.tile-content-body-copy > p:not(:last-child):not(:has(+ table)),
|
|
354
|
+
.split-module-body > p:not(:last-child):not(:has(+ table)),
|
|
355
|
+
.accordion-item-body > div > p:not(:last-child):not(:has(+ table)),
|
|
356
|
+
.content-module-body-copy > :is(ul, ol):not(:last-child):not(:has(+ table)),
|
|
357
|
+
.body-copy-with-lists > :is(ul, ol):not(:last-child):not(:has(+ table)),
|
|
358
|
+
.tile-content-body-copy > :is(ul, ol):not(:last-child):not(:has(+ table)),
|
|
359
|
+
.split-module-body > :is(ul, ol):not(:last-child):not(:has(+ table)),
|
|
360
|
+
.accordion-item-body > div > :is(ul, ol):not(:last-child):not(:has(+ table)) {
|
|
361
|
+
margin-bottom: 1em;
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
/*
|
|
365
|
+
* Contentful double-enter becomes an empty paragraph (<p></p>).
|
|
366
|
+
* Empty blocks have zero height and their margins collapse with
|
|
367
|
+
* neighbors, so the blank line disappears. Give them one line of
|
|
368
|
+
* height instead of injecting <br> in the consumer parser.
|
|
369
|
+
*/
|
|
370
|
+
.content-module-body-copy > p:empty,
|
|
371
|
+
.body-copy-with-lists > p:empty,
|
|
372
|
+
.tile-content-body-copy > p:empty,
|
|
373
|
+
.split-module-body > p:empty,
|
|
374
|
+
.accordion-item-body > div > p:empty {
|
|
375
|
+
min-height: 1em;
|
|
376
|
+
}
|
|
377
|
+
|
|
339
378
|
.container-collection-headline {
|
|
340
379
|
max-width: 15ch;
|
|
341
380
|
white-space: pre-line;
|