@workday/canvas-kit-react-fonts 15.0.4 → 15.0.5

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.
Files changed (2) hide show
  1. package/README.md +7 -6
  2. package/package.json +2 -2
package/README.md CHANGED
@@ -25,6 +25,7 @@ Then in your index or main file of your project...
25
25
 
26
26
  ```tsx
27
27
  import {Global, css} from '@emotion/react';
28
+
28
29
  import {fonts} from '@workday/canvas-kit-react-fonts';
29
30
 
30
31
  // Inject all of Canvas' @font-face declarations to <head> via emotion
@@ -52,15 +53,15 @@ render(
52
53
  or
53
54
 
54
55
  ```tsx
55
- import styled from '@emotion/styled';
56
- import {fontFamily, monoFontFamily} from '@workday/canvas-kit-react/tokens';
56
+ import {createStyles} from '@workday/canvas-kit-styling';
57
+ import {system} from '@workday/canvas-tokens-web';
57
58
 
58
59
  // Custom typography using the official Canvas font list
59
- const customParagraph = styled('p')({
60
- fontFamily: fontFamily, // "Roboto", "Helvetica Neue", "Helvetica", Arial, sans-serif
60
+ const customParagraph = createStyles({
61
+ fontFamily: system.fontFamily.default, // "Roboto", "Helvetica Neue", "Helvetica", Arial, sans-serif
61
62
  });
62
63
 
63
- const customPre = styled('pre')({
64
- fontFamily: monoFontFamily, // "Roboto Mono", "Courier New", Courier, monospace
64
+ const customPre = createStyles({
65
+ fontFamily: system.fontFamily.mono, // "Roboto Mono", "Courier New", Courier, monospace
65
66
  });
66
67
  ```
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@workday/canvas-kit-react-fonts",
3
- "version": "15.0.4",
3
+ "version": "15.0.5",
4
4
  "description": "Fonts for canvas-kit-react",
5
5
  "author": "Workday, Inc. (https://www.workday.com)",
6
6
  "license": "Apache-2.0",
@@ -43,5 +43,5 @@
43
43
  "dependencies": {
44
44
  "@emotion/react": "^11.7.1"
45
45
  },
46
- "gitHead": "f942653d6e32c211030ea73fddebf3af11856056"
46
+ "gitHead": "7f80a853021fa7151423761ec2cedc5f310b99a4"
47
47
  }