From e0e953ff9abce35adb3666843121bcbbff8e93cf Mon Sep 17 00:00:00 2001 From: aveline Date: Mon, 7 Feb 2022 15:27:41 -0800 Subject: [PATCH 1/3] Migration guidance for `em()` --- documentation/guides/migrating-from-v8-to-v9.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index 32ea7d24904..e6d1ee82d72 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -100,6 +100,10 @@ A list of functions/mixins and their value equivalents or new token values. | `duration(slower)` | `--p-duration-400` | | `duration(slowest)` | `--p-duration-500` | +#### `em()` + +Any usage of this function can be hardcoded to `em` units. Alternatively, values can also be hardcoded to `px` units, which will automatically be converted to `rem` in postcss. + #### `easing()` | Function | Replacement Value/Token | From 804ea3b203ba2c47774d85f6d12860290f555a39 Mon Sep 17 00:00:00 2001 From: aveline Date: Mon, 7 Feb 2022 16:27:45 -0800 Subject: [PATCH 2/3] Update migrating-from-v8-to-v9.md --- documentation/guides/migrating-from-v8-to-v9.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index e6d1ee82d72..7b6fa310748 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -102,7 +102,9 @@ A list of functions/mixins and their value equivalents or new token values. #### `em()` -Any usage of this function can be hardcoded to `em` units. Alternatively, values can also be hardcoded to `px` units, which will automatically be converted to `rem` in postcss. +| Function | Source to copy | +| -------- | -------------------- | +| `px()` | [link to function]() | #### `easing()` From 308e85f7703f0d92a4db52c6e6e698c243c2b43e Mon Sep 17 00:00:00 2001 From: aveline Date: Wed, 9 Feb 2022 13:25:46 -0800 Subject: [PATCH 3/3] Update em() definition link --- documentation/guides/migrating-from-v8-to-v9.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/documentation/guides/migrating-from-v8-to-v9.md b/documentation/guides/migrating-from-v8-to-v9.md index 4b24acd7990..84fa0794e70 100644 --- a/documentation/guides/migrating-from-v8-to-v9.md +++ b/documentation/guides/migrating-from-v8-to-v9.md @@ -151,9 +151,10 @@ A list of functions/mixins and their value equivalents or new token values. #### `em()` -| Function | Source to copy | +This function has been deprecated, but the definition can be copied and used locally. +| Function | Source | | -------- | -------------------- | -| `px()` | [link to function]() | +| `em()` | [definition](https://github.com/Shopify/polaris-react/blob/b443d114d447df15d9e72914c8ca5058439a175e/documentation/guides/legacy-polaris-v8-public-api.scss#L333) | #### `easing()`