@universal-tennis/ui-shared 0.0.21 → 0.0.23

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.
@@ -1,4 +1,4 @@
1
- import "./variables.css";
1
+ import "./typography.css";
2
2
 
3
3
  export const parameters = {
4
4
  actions: { argTypesRegex: "^on[A-Z].*" },
@@ -1,5 +1,4 @@
1
1
  // ATOMS
2
- import "./stories/assets/css/variables.css";
3
2
  export { default as Button } from './stories/atoms/Button/Button';
4
3
  export { default as Typography } from './stories/atoms/Typography/Typography';
5
4
  // MOLECULES
@@ -1 +1 @@
1
- {"version":3,"file":"components.js","sourceRoot":"","sources":["../src/components.jsx"],"names":[],"mappings":"AAAA,QAAQ;AACR,OAAO,oCAAoC,CAAC;AAE5C,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,uCAAuC,CAAC;AAE9E,YAAY;AACZ,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,uCAAuC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AAEzE,aAAa"}
1
+ {"version":3,"file":"components.js","sourceRoot":"","sources":["../src/components.jsx"],"names":[],"mappings":"AAAA,QAAQ;AACR,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,+BAA+B,CAAC;AAClE,OAAO,EAAE,OAAO,IAAI,UAAU,EAAE,MAAM,uCAAuC,CAAC;AAE9E,YAAY;AACZ,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,uCAAuC,CAAC;AAC/E,OAAO,EAAE,OAAO,IAAI,QAAQ,EAAE,MAAM,oCAAoC,CAAC;AAEzE,aAAa"}
@@ -12,6 +12,7 @@ var __rest = (this && this.__rest) || function (s, e) {
12
12
  import React from 'react';
13
13
  import MuiButton from '@mui/material/Button';
14
14
  import { styled } from '@mui/material/styles';
15
+ import { colors } from '../../theme/colors';
15
16
  const StyledButton = styled(MuiButton)({
16
17
  borderRadius: '24px',
17
18
  fontSize: '12px',
@@ -25,33 +26,33 @@ const StyledButton = styled(MuiButton)({
25
26
  },
26
27
  });
27
28
  const PrimaryButton = styled(StyledButton)((props) => ({
28
- backgroundColor: 'var(--black)',
29
- color: 'var(--white)',
29
+ backgroundColor: colors.black,
30
+ color: colors.white,
30
31
  width: props.isExpanded ? '100%' : 'inherit',
31
32
  '&:hover': {
32
- backgroundColor: 'var(--darkest-grey)',
33
- borderColor: 'var(--darkest-grey)',
33
+ backgroundColor: colors.darkestGrey,
34
+ borderColor: colors.darkestGrey,
34
35
  },
35
36
  '&:disabled': {
36
- backgroundColor: 'var(--lightest-grey)',
37
- borderColor: 'var(--lightest-grey)',
37
+ backgroundColor: colors.lightGrey,
38
+ borderColor: colors.lightGrey,
38
39
  },
39
40
  }));
40
41
  const SecondaryButton = styled(StyledButton)({
41
- borderColor: 'var(--black)',
42
+ borderColor: colors.black,
42
43
  backgroundColor: 'transparent',
43
- color: 'var(--black)',
44
+ color: colors.black,
44
45
  '&:hover': {
45
- borderColor: 'var(--darkest-grey)',
46
+ borderColor: colors.darkestGrey,
46
47
  },
47
48
  '&:disabled': {
48
- borderColor: 'var(--disabled)'
49
+ borderColor: colors.disabled
49
50
  },
50
51
  });
51
52
  const LinkButton = styled(MuiButton)({
52
53
  borderColor: 'transparent',
53
54
  backgroundColor: 'transparent',
54
- color: 'var(--primary)',
55
+ color: colors.primary,
55
56
  textTransform: 'inherit',
56
57
  justifyContent: 'left',
57
58
  padding: 0,
@@ -59,7 +60,7 @@ const LinkButton = styled(MuiButton)({
59
60
  backgroundColor: 'transparent',
60
61
  },
61
62
  '&:disabled': {
62
- borderColor: 'var(--disabled)'
63
+ borderColor: colors.disabled
63
64
  },
64
65
  });
65
66
  export default function Button(_a) {
@@ -1 +1 @@
1
- {"version":3,"file":"Button.js","sourceRoot":"","sources":["../../../../src/stories/atoms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,gBAAgB;IACvB,aAAa,EAAE,SAAS;IACxB,cAAc,EAAE,MAAM;IACtB,OAAO,EAAE,CAAC;IAEV,SAAS,EAAE;QACT,eAAe,EAAE,aAAa;KAC/B;IAED,YAAY,EAAE;QACZ,WAAW,EAAE,iBAAiB;KAC/B;CACF,CAAC,CAAC;AAEH,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAA6C;QAA7C,EAAE,QAAQ,EAAE,QAAQ,OAAyB,EAApB,KAAK,cAA9B,wBAAgC,CAAF;IAC3D,QAAQ,QAAQ,EAAE;QAChB,KAAK,SAAS;YACZ,OAAO,CACL,oBAAC,aAAa,oBACR,KAAK,GAER,QAAQ,CACK,CACjB,CAAC;QACJ,KAAK,kBAAkB;YACrB,OAAO,CACH,oBAAC,aAAa,kBACZ,UAAU,UACN,KAAK,GAER,QAAQ,CACK,CACnB,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,CACL,oBAAC,eAAe,oBACV,KAAK,GAER,QAAQ,CACO,CACnB,CAAC;QACJ,KAAK,MAAM;YACT,OAAO,CACH,oBAAC,UAAU,kBACT,kBAAkB,UACd,KAAK,GAER,QAAQ,CACE,CAChB,CAAC;QACJ;YACE,OAAO,CACH,oBAAC,YAAY,oBACP,KAAK,GAEV,QAAQ,CACM,CAClB,CAAC;KACL;AACH,CAAC"}
1
+ {"version":3,"file":"Button.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Button/Button.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,SAAS,MAAM,sBAAsB,CAAC;AAC7C,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAC,MAAM,EAAC,MAAM,oBAAoB,CAAC;AAa1C,MAAM,YAAY,GAAG,MAAM,CAAC,SAAS,CAAC,CAAC;IACrC,YAAY,EAAE,MAAM;IACpB,QAAQ,EAAE,MAAM;IAChB,OAAO,EAAE,QAAQ;IACj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KAC7B;CACF,CAAC,CAAC;AAEH,MAAM,CAAC,OAAO,UAAU,MAAM,CAAC,EAA6C;QAA7C,EAAE,QAAQ,EAAE,QAAQ,OAAyB,EAApB,KAAK,cAA9B,wBAAgC,CAAF;IAC3D,QAAQ,QAAQ,EAAE;QAChB,KAAK,SAAS;YACZ,OAAO,CACL,oBAAC,aAAa,oBACR,KAAK,GAER,QAAQ,CACK,CACjB,CAAC;QACJ,KAAK,kBAAkB;YACrB,OAAO,CACH,oBAAC,aAAa,kBACZ,UAAU,UACN,KAAK,GAER,QAAQ,CACK,CACnB,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,CACL,oBAAC,eAAe,oBACV,KAAK,GAER,QAAQ,CACO,CACnB,CAAC;QACJ,KAAK,MAAM;YACT,OAAO,CACH,oBAAC,UAAU,kBACT,kBAAkB,UACd,KAAK,GAER,QAAQ,CACE,CAChB,CAAC;QACJ;YACE,OAAO,CACH,oBAAC,YAAY,oBACP,KAAK,GAEV,QAAQ,CACM,CAClB,CAAC;KACL;AACH,CAAC"}
@@ -1,5 +1,4 @@
1
1
  import React, { ReactElement } from 'react';
2
- import "../../assets/css/typography.css";
3
2
  type TypographyProps = {
4
3
  children: string | ReactElement;
5
4
  category?: string;
@@ -12,7 +12,6 @@ var __rest = (this && this.__rest) || function (s, e) {
12
12
  import React from 'react';
13
13
  import MuiTypography from '@mui/material/Typography';
14
14
  import { styled } from '@mui/material/styles';
15
- import "../../assets/css/typography.css";
16
15
  const DISPLAY_SIZES = {
17
16
  "XXX-large": '120px',
18
17
  "XX-large": '100px',
@@ -47,17 +46,17 @@ const SECONDARY_SIZES = {
47
46
  "xx-small-book": '10px',
48
47
  };
49
48
  const DisplayTypography = styled(MuiTypography)((props) => ({
50
- fontFamily: 'var(--display-font)',
49
+ fontFamily: `'UTR Numerals', 'Tungsten A', 'Tungsten B'`,
51
50
  fontSize: DISPLAY_SIZES[props.size],
52
51
  fontWeight: props.weight
53
52
  }));
54
53
  const PrimaryTypography = styled(MuiTypography)((props) => ({
55
- fontFamily: 'var(--primary-font)',
54
+ fontFamily: `'Tungsten A', 'Tungsten B', 'Helvetica', Arial, sans-serif`,
56
55
  fontSize: PRIMARY_SIZES[props.size],
57
56
  fontWeight: props.weight
58
57
  }));
59
58
  const SecondaryTypography = styled(MuiTypography)((props) => ({
60
- fontFamily: 'var(--secondary-font)',
59
+ fontFamily: `'Gotham SSm A', 'Gotham SSm B', 'Helvetica', Arial, sans-serif`,
61
60
  fontSize: SECONDARY_SIZES[props.size],
62
61
  textTransform: props.isCap ? 'uppercase' : 'inherit',
63
62
  fontWeight: props.weight
@@ -1 +1 @@
1
- {"version":3,"file":"Typography.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Typography/Typography.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,aAAa,MAAM,0BAA0B,CAAC;AACrD,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,iCAAiC,CAAC;AAezC,MAAM,aAAa,GAAG;IACpB,WAAW,EAAE,OAAO;IACpB,UAAU,EAAE,OAAO;IACnB,SAAS,EAAE,MAAM;IACjB,KAAK,EAAE,MAAM;IACb,aAAa,EAAE,MAAM;IACrB,aAAa,EAAE,MAAM;CACtB,CAAC;AAEF,MAAM,aAAa,GAAG;IACpB,YAAY,EAAE,MAAM;IACpB,YAAY,EAAE,MAAM;IACpB,aAAa,EAAE,MAAM;IACrB,iBAAiB,EAAE,MAAM;IACzB,eAAe,EAAE,MAAM;IACvB,aAAa,EAAE,MAAM;IACrB,YAAY,EAAE,MAAM;IACpB,cAAc,EAAE,MAAM;CACvB,CAAC;AAEF,MAAM,eAAe,GAAG;IACtB,cAAc,EAAE,MAAM;IACtB,YAAY,EAAE,MAAM;IACpB,eAAe,EAAE,MAAM;IACvB,aAAa,EAAE,MAAM;IACrB,kBAAkB,EAAE,MAAM;IAC1B,cAAc,EAAE,MAAM;IACt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B,CAAC;KACL;AACH,CAAC"}
1
+ {"version":3,"file":"Typography.js","sourceRoot":"","sources":["../../../../src/stories/atoms/Typography/Typography.tsx"],"names":[],"mappings":";;;;;;;;;;;AAAA,OAAO,KAAqB,MAAM,OAAO,CAAC;AAC1C,OAAO,aAAa,MAAM,0BAA0B,CAAC;AACrD,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAe9C,MAAM,aAAa,GAAG;IACpB,WAAW,EAAE,OAAO;IACpB,UAAU,EAAE,OAAO;IACnB,SAAS,EAAE,MAAM;IACjB,KAAK,EAAE,MAAM;IACb,aAAa,EAAE,MAAM;IACrB,aAAa,EAAE,MAAM;CACtB,CAAC;AAEF,MAAM,aAAa,GAAG;IACpB,YAAY,EAAE,MAAM;IACpB,YAAY,EAAE,MAAM;IACpB,aAAa,EAAE,MAAM;IACrB,iBAAiB,EAAE,MAAM;IACzB,eAAe,EAAE,MAAM;IACvB,aAAa,EAAE,MAAM;IACrB,YAAY,EAAE,MAAM;IACpB,cAAc,EAAE,MAAM;CACvB,CAAC;AAEF,MAAM,eAAe,GAAG;IACtB,cAAc,EAAE,MAAM;IACtB,YAAY,EAAE,MAAM;IACpB,eAAe,EAAE,MAAM;IACvB,aAAa,EAAE,MAAM;IACrB,kBAAkB,EAAE,MAAM;IAC1B,cAAc,EAAE,MAAM;IACtB,YAAY,EAAE,MAAM;IACpB,oBAAoB,EAAE,MAAM;IAC5B,gBAAgB,EAAE,MAAM;IACxB,kBAAkB,EAAE,MAAM;IAC1B,cAAc,EAAE,MAAM;IACtB,qBAAqB,EAAE,MAAM;IAC7B,eAAe,EAAE,MAAM;CACxB,CAAC;AAEF,MAAM,iBAAiB,GAAG,MAAM,CAAC,aAAa,CAAC,CAAC,CAAC,KAAyB,EAAE,EAAE,CAAC,CAAC;IAC9E,UAAU,EAAE,4CAA4C;IACxD,QAAQ,EAAE,aAAa,CAAC,KAAK,CAAC,IAAkC,CAAC;IACjE,UAAU,EAAE,KAAK,CA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AAK,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,QAAQ,CAAC,UAAU,CAAC;YAC7B,MAAM,GAAG,GAAG,CAAC;YACb,MAAM;QAER,KAAK,IAAI,aAAJ,IAAI,uBAAJ,IAAI,CAAE,QAAQ,CAAC,MAAM,CAAC;YACzB,MAAM,GAAG,GAAG,CAAC;YAEb,MAAM;QACR;YACE,MAAM,GAAG,GAAG,CAAC;YAEb,MAAM;KACT;IAED,QAAQ,QAAQ,EAAE;QAChB,KAAK,SAAS;YACZ,OAAO,CACL,oBAAC,iBAAiB,kBAChB,IAAI,EAAE,IAAI,IACN,KAAK,GAER,QAAQ,CACS,CACrB,CAAC;QACJ,KAAK,WAAW;YACd,OAAO,CACL,oBAAC,mBAAmB,kBAClB,IAAI,EAAE,IAAI,EACV,KAAK,EAAE,KAAK,EACZ,MAAM,EAAE,MAAM,IACV,KAAK,GAER,QAAQ,CACW,CACvB,CAAC;QACJ,KAAK,SAAS;YACZ,OAAO,CACL,oBAAC,iBAAiB,kBAChB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,IACV,KAAK,GAER,QAAQ,CACS,CACrB,CAAC;QACJ;YACE,OAAO,CACH,oBAAC,iBAAiB,kBAChB,IAAI,EAAE,IAAI,EACV,MAAM,EAAE,MAAM,IACV,KAAK,GAEV,QAAQ,CACW,CACvB,CAAC;KACL;AACH,CAAC"}
@@ -1,11 +1,12 @@
1
1
  import Box from '@mui/material/Box';
2
2
  import { styled } from '@mui/material/styles';
3
+ import { colors } from 'stories/theme/colors';
3
4
  export const StyledCard = styled(Box)({
4
5
  display: 'flex',
5
6
  flexDirection: 'column',
6
7
  borderRadius: '4px',
7
8
  padding: '16px',
8
- border: '1px solid var(--cool-grey-300)',
9
+ border: `1px solid ${colors.coolGrey300}`,
9
10
  '&:hover': {
10
11
  cursor: 'pointer'
11
12
  },
@@ -1 +1 @@
1
- {"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../../src/stories/molecules/Cards/shared.tsx"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,mBAAmB,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;IACpC,OAAO,EAAE,MAAM;IACf,aAAa,EAAE,QAAQ;IACvB,YAAY,EAAE,KAAK;IACnB,OAAO,EAAE,MAAM;IACf,MAAM,EAAE,gCAAgC;IAExC,SAAS,EAAE;QACT,MAAM,EAAE,SAAS;KAClB;CACF,CAAC,CAAC"}
1
+ {"version":3,"file":"shared.js","sourceRoot":"","sources":["../../../../src/stories/molecules/Cards/shared.tsx"],"names":[],"mappings":"AAAA,OAAO,GAAG,MAAM,mBAAmB,CAAC;AACpC,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAC9C,OAAO,EAAE,MAAM,EAAE,MAAM,sBAAsB,CAAC;AAE9C,MAAM,CAAC,MAAM,UAAU,GAAG,MAAM,CAAC,GAAG,CAAC,CAAC;IACpC,OAAO,EAAE,MAAM;IACf,aAAa,EAAE,QAAQ;IACvB,YAAY,EAAE,KAAK;IACnB,OAAO,EAAE,MAAM;IACf,MAAM,EAAE,aAAa,MAAM,CAAC,WAAW,EAAE;IAEzC,SAAS,EAAE;QACT,MAAM,EAAE,SAAS;KAClB;CACF,CAAC,CAAC"}
@@ -0,0 +1,10 @@
1
+ export declare const colors: {
2
+ primary: string;
3
+ secondary: string;
4
+ disabled: string;
5
+ black: string;
6
+ white: string;
7
+ lightGrey: string;
8
+ darkestGrey: string;
9
+ coolGrey300: string;
10
+ };
@@ -0,0 +1,11 @@
1
+ export const colors = {
2
+ primary: '#008ded',
3
+ secondary: '#e0004f',
4
+ disabled: '#bac6d6',
5
+ black: '#000',
6
+ white: '#fff',
7
+ lightGrey: '#d7e0ea',
8
+ darkestGrey: '#3b4859',
9
+ coolGrey300: '#DDE3EB'
10
+ };
11
+ //# sourceMappingURL=colors.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"colors.js","sourceRoot":"","sources":["../../../src/stories/theme/colors.ts"],"names":[],"mappings":"AAAA,MAAM,CAAC,MAAM,MAAM,GAAG;IACpB,OAAO,EAAE,SAAS;IAClB,SAAS,EAAE,SAAS;IACpB,QAAQ,EAAE,SAAS;IACnB,KAAK,EAAE,MAAM;IACb,KAAK,EAAE,MAAM;IACb,SAAS,EAAE,SAAS;IACpB,WAAW,EAAE,SAAS;IACtB,WAAW,EAAE,SAAS;CACvB,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@universal-tennis/ui-shared",
3
- "version": "0.0.21",
3
+ "version": "0.0.23",
4
4
  "main": "dist/items.js",
5
5
  "license": "MIT",
6
6
  "homepage": "https://universaltennis.com",
@@ -1,6 +1,4 @@
1
1
  // ATOMS
2
- import "./stories/assets/css/variables.css";
3
-
4
2
  export { default as Button } from './stories/atoms/Button/Button';
5
3
  export { default as Typography } from './stories/atoms/Typography/Typography';
6
4
 
package/src/custom.d.ts CHANGED
@@ -11,8 +11,3 @@ declare module '*.svg' {
11
11
  const src: string;
12
12
  export default src;
13
13
  }
14
-
15
- declare module '*.css' {
16
- const classes: { [key: string]: string };
17
- export default classes;
18
- }
@@ -1,6 +1,7 @@
1
1
  import React, {ReactElement} from 'react';
2
2
  import MuiButton from '@mui/material/Button';
3
3
  import { styled } from '@mui/material/styles';
4
+ import {colors} from '../../theme/colors';
4
5
 
5
6
  type ButtonProps = {
6
7
  children: string | ReactElement;
@@ -28,37 +29,37 @@ const StyledButton = styled(MuiButton)({
28
29
  });
29
30
 
30
31
  const PrimaryButton = styled(StyledButton)((props: StyledButtonProps) => ({
31
- backgroundColor: 'var(--black)',
32
- color: 'var(--white)',
32
+ backgroundColor: colors.black,
33
+ color: colors.white,
33
34
  width: props.isExpanded ? '100%' : 'inherit',
34
35
 
35
36
  '&:hover': {
36
- backgroundColor: 'var(--darkest-grey)',
37
- borderColor: 'var(--darkest-grey)',
37
+ backgroundColor: colors.darkestGrey,
38
+ borderColor: colors.darkestGrey,
38
39
  },
39
40
  '&:disabled': {
40
- backgroundColor: 'var(--lightest-grey)',
41
- borderColor: 'var(--lightest-grey)',
41
+ backgroundColor: colors.lightGrey,
42
+ borderColor: colors.lightGrey,
42
43
  },
43
44
  }));
44
45
 
45
46
  const SecondaryButton = styled(StyledButton)({
46
- borderColor: 'var(--black)',
47
+ borderColor: colors.black,
47
48
  backgroundColor: 'transparent',
48
- color: 'var(--black)',
49
+ color: colors.black,
49
50
 
50
51
  '&:hover': {
51
- borderColor: 'var(--darkest-grey)',
52
+ borderColor: colors.darkestGrey,
52
53
  },
53
54
  '&:disabled': {
54
- borderColor: 'var(--disabled)'
55
+ borderColor: colors.disabled
55
56
  },
56
57
  });
57
58
 
58
59
  const LinkButton = styled(MuiButton)({
59
60
  borderColor: 'transparent',
60
61
  backgroundColor: 'transparent',
61
- color: 'var(--primary)',
62
+ color: colors.primary,
62
63
  textTransform: 'inherit',
63
64
  justifyContent: 'left',
64
65
  padding: 0,
@@ -68,7 +69,7 @@ const LinkButton = styled(MuiButton)({
68
69
  },
69
70
 
70
71
  '&:disabled': {
71
- borderColor: 'var(--disabled)'
72
+ borderColor: colors.disabled
72
73
  },
73
74
  });
74
75
 
@@ -1,7 +1,6 @@
1
1
  import React, {ReactElement} from 'react';
2
2
  import MuiTypography from '@mui/material/Typography';
3
3
  import { styled } from '@mui/material/styles';
4
- import "../../assets/css/typography.css";
5
4
 
6
5
  type TypographyProps = {
7
6
  children: string | ReactElement;
@@ -53,19 +52,19 @@ const SECONDARY_SIZES = {
53
52
  };
54
53
 
55
54
  const DisplayTypography = styled(MuiTypography)((props: MuiTypographyProps) => ({
56
- fontFamily: 'var(--display-font)',
55
+ fontFamily: `'UTR Numerals', 'Tungsten A', 'Tungsten B'`,
57
56
  fontSize: DISPLAY_SIZES[props.size as keyof typeof DISPLAY_SIZES],
58
57
  fontWeight: props.weight
59
58
  }));
60
59
 
61
60
  const PrimaryTypography = styled(MuiTypography)((props: MuiTypographyProps) => ({
62
- fontFamily: 'var(--primary-font)',
61
+ fontFamily: `'Tungsten A', 'Tungsten B', 'Helvetica', Arial, sans-serif`,
63
62
  fontSize: PRIMARY_SIZES[props.size as keyof typeof PRIMARY_SIZES],
64
63
  fontWeight: props.weight
65
64
  }));
66
65
 
67
66
  const SecondaryTypography = styled(MuiTypography)((props: MuiTypographyProps) => ({
68
- fontFamily: 'var(--secondary-font)',
67
+ fontFamily: `'Gotham SSm A', 'Gotham SSm B', 'Helvetica', Arial, sans-serif`,
69
68
  fontSize: SECONDARY_SIZES[props.size as keyof typeof SECONDARY_SIZES],
70
69
  textTransform: props.isCap ? 'uppercase' : 'inherit',
71
70
  fontWeight: props.weight
@@ -1,12 +1,13 @@
1
1
  import Box from '@mui/material/Box';
2
2
  import { styled } from '@mui/material/styles';
3
+ import { colors } from 'stories/theme/colors';
3
4
 
4
5
  export const StyledCard = styled(Box)({
5
6
  display: 'flex',
6
7
  flexDirection: 'column',
7
8
  borderRadius: '4px',
8
9
  padding: '16px',
9
- border: '1px solid var(--cool-grey-300)',
10
+ border: `1px solid ${colors.coolGrey300}`,
10
11
 
11
12
  '&:hover': {
12
13
  cursor: 'pointer'
@@ -0,0 +1,10 @@
1
+ export const colors = {
2
+ primary: '#008ded',
3
+ secondary: '#e0004f',
4
+ disabled: '#bac6d6',
5
+ black: '#000',
6
+ white: '#fff',
7
+ lightGrey: '#d7e0ea',
8
+ darkestGrey: '#3b4859',
9
+ coolGrey300: '#DDE3EB'
10
+ };
package/tsconfig.json CHANGED
@@ -17,7 +17,6 @@
17
17
  "baseUrl": "src",
18
18
  "allowSyntheticDefaultImports": true,
19
19
  "noImplicitAny": true,
20
- "plugins": [{ "name": "typescript-plugin-css-modules" }]
21
20
  },
22
21
  "exclude": [
23
22
  "node_modules",
@@ -1,12 +0,0 @@
1
- :root {
2
- --primary: #008ded;
3
- --secondary: #e0004f;
4
- --disabled: #bac6d6;
5
- --black: #000;
6
- --white: #fff;
7
- --light-grey: #d7e0ea;
8
- --darkest-grey: #3b4859;
9
-
10
- /* colors */
11
- --cool-grey-300: #DDE3EB;
12
- }
@@ -1,12 +0,0 @@
1
- :root {
2
- --primary: #008ded;
3
- --secondary: #e0004f;
4
- --disabled: #bac6d6;
5
- --black: #000;
6
- --white: #fff;
7
- --light-grey: #d7e0ea;
8
- --darkest-grey: #3b4859;
9
-
10
- /* colors */
11
- --cool-grey-300: #DDE3EB;
12
- }