From 8ad354f3d958a27f303a3d20c153075d293a932d Mon Sep 17 00:00:00 2001 From: Romello Goodman Date: Wed, 9 Feb 2022 18:01:03 -0500 Subject: [PATCH 1/3] Add documentation for hidden-when-printing, print-hidden, when-not-printing, when-printing functions --- .../guides/migrating-from-v8-to-v9.md | 32 +++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index ad7633c3402..2d428af0b6e 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -234,6 +234,16 @@ We replaced a few of the following filter function instances with color tokens i | `font-family()`
`font-family($family: base)` | `--p-font-family-sans` | | `font-family($family: 'monospace')` | `--p-font-family-mono` | +#### `hidden-when-printing()` + +Replace any instance of `@include hidden-when-printing;` with the following code + +```scss +@media print { + display: none !important; +} +``` + #### `high-contrast-border()` | Mixin | Replacement Value/Token | @@ -268,6 +278,16 @@ For `` instances that are hard coded values, see if you can replac | `ms-high-contrast-color('button-text-background')` | `buttonFace` | | `ms-high-contrast-color('background')` | `window` | +#### `print-hidden()` + +Replace any instance of `@include print-hidden;` with the following code + +```scss +@media print { + display: none !important; +} +``` + #### `rem()` This function has been deprecated, but the definition can be copied and used locally. @@ -321,6 +341,18 @@ padding: 0; list-style: none; ``` +#### `when-not-printing()` + +| Function | Replacement Value/Token | +|------------------------------|-------------------------| +| `@include when-not-printing` | `@media not print` | + +#### `when-printing()` + +| Function | Replacement Value/Token | +|------------------------------|-------------------------| +| `@include when-printing` | `@media print` | + ## Tokens ### Border Radius From 8242846aa7075747bfddd611aebaeee67c480d7d Mon Sep 17 00:00:00 2001 From: Romello Goodman Date: Thu, 10 Feb 2022 11:52:24 -0500 Subject: [PATCH 2/3] Update documentation/guides/migrating-from-v8-to-v9.md Co-authored-by: Laura Griffee --- documentation/guides/migrating-from-v8-to-v9.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index 2d428af0b6e..cc4f0e6f3dc 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -343,7 +343,7 @@ list-style: none; #### `when-not-printing()` -| Function | Replacement Value/Token | +| Mixin | Replacement Value/Token | |------------------------------|-------------------------| | `@include when-not-printing` | `@media not print` | From ec3f0b50f89c1ee272e367a76f8fbf748c248dd4 Mon Sep 17 00:00:00 2001 From: Romello Goodman Date: Thu, 10 Feb 2022 11:52:47 -0500 Subject: [PATCH 3/3] Update documentation/guides/migrating-from-v8-to-v9.md Co-authored-by: Laura Griffee --- documentation/guides/migrating-from-v8-to-v9.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index cc4f0e6f3dc..083c3b9cdde 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -349,7 +349,7 @@ list-style: none; #### `when-printing()` -| Function | Replacement Value/Token | +| Mixin | Replacement Value/Token | |------------------------------|-------------------------| | `@include when-printing` | `@media print` |