From 6ad5a199af2cdfdddb31e7147ddeb32932faa28e Mon Sep 17 00:00:00 2001 From: Adam Wathan Date: Wed, 21 Oct 2020 16:21:28 -0400 Subject: [PATCH] Set font on body and on html (#2643) modern-normalize sets it on `body` so we need to defeat that. --- __tests__/fixtures/tailwind-output-flagged.css | 2 +- __tests__/fixtures/tailwind-output-important.css | 2 +- __tests__/fixtures/tailwind-output-no-color-opacity.css | 2 +- __tests__/fixtures/tailwind-output.css | 2 +- src/plugins/css/preflight.css | 2 +- 5 files changed, 5 insertions(+), 5 deletions(-) diff --git a/__tests__/fixtures/tailwind-output-flagged.css b/__tests__/fixtures/tailwind-output-flagged.css index 227c23369..1d2aef391 100644 --- a/__tests__/fixtures/tailwind-output-flagged.css +++ b/__tests__/fixtures/tailwind-output-flagged.css @@ -361,7 +361,7 @@ ul { * to override it to ensure consistency even when using the default theme. */ -html { +html, body { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 1 */ line-height: 1.5; /* 2 */ } diff --git a/__tests__/fixtures/tailwind-output-important.css b/__tests__/fixtures/tailwind-output-important.css index fedf61764..f3acec3d3 100644 --- a/__tests__/fixtures/tailwind-output-important.css +++ b/__tests__/fixtures/tailwind-output-important.css @@ -361,7 +361,7 @@ ul { * to override it to ensure consistency even when using the default theme. */ -html { +html, body { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 1 */ line-height: 1.5; /* 2 */ } diff --git a/__tests__/fixtures/tailwind-output-no-color-opacity.css b/__tests__/fixtures/tailwind-output-no-color-opacity.css index 3b76b4063..1d8d65c5a 100644 --- a/__tests__/fixtures/tailwind-output-no-color-opacity.css +++ b/__tests__/fixtures/tailwind-output-no-color-opacity.css @@ -361,7 +361,7 @@ ul { * to override it to ensure consistency even when using the default theme. */ -html { +html, body { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 1 */ line-height: 1.5; /* 2 */ } diff --git a/__tests__/fixtures/tailwind-output.css b/__tests__/fixtures/tailwind-output.css index 227c23369..1d2aef391 100644 --- a/__tests__/fixtures/tailwind-output.css +++ b/__tests__/fixtures/tailwind-output.css @@ -361,7 +361,7 @@ ul { * to override it to ensure consistency even when using the default theme. */ -html { +html, body { font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"; /* 1 */ line-height: 1.5; /* 2 */ } diff --git a/src/plugins/css/preflight.css b/src/plugins/css/preflight.css index bff5bb83a..db3f9ad78 100644 --- a/src/plugins/css/preflight.css +++ b/src/plugins/css/preflight.css @@ -62,7 +62,7 @@ ul { * to override it to ensure consistency even when using the default theme. */ -html { +html, body { font-family: theme('fontFamily.sans', ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"); /* 1 */ line-height: 1.5; /* 2 */ }