@xyo-network/react-theme 2.26.32 → 2.26.35
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.
- package/README.md +2 -1
- package/dist/docs.json +10 -1
- package/package.json +3 -3
- package/babel.config.json +0 -5
- package/src/appThemeOptions.tsx +0 -30
- package/src/fontFamily.ts +0 -1
- package/src/index.ts +0 -6
- package/src/partialDarkThemeOptions.tsx +0 -28
- package/src/partialLightThemeOptions.tsx +0 -24
- package/src/themeOptions.ts +0 -103
- package/src/webThemeOptions.tsx +0 -8
package/README.md
CHANGED
|
@@ -10,7 +10,8 @@
|
|
|
10
10
|
[![codeclimate-badge][]][codeclimate-link]
|
|
11
11
|
[![snyk-badge][]][snyk-link]
|
|
12
12
|
|
|
13
|
-
> The XYO Foundation provides this source code available in our efforts to
|
|
13
|
+
> The XYO Foundation provides this source code available in our efforts to
|
|
14
|
+
> advance the understanding of the XYO Procotol and its possible uses.
|
|
14
15
|
|
|
15
16
|
## Table of Contents
|
|
16
17
|
|
package/dist/docs.json
CHANGED
|
@@ -2,6 +2,15 @@
|
|
|
2
2
|
"id": 0,
|
|
3
3
|
"name": "@xyo-network/react-theme",
|
|
4
4
|
"kind": 1,
|
|
5
|
+
"kindString": "Project",
|
|
5
6
|
"flags": {},
|
|
6
|
-
"originalName": ""
|
|
7
|
+
"originalName": "",
|
|
8
|
+
"sources": [
|
|
9
|
+
{
|
|
10
|
+
"fileName": "index.ts",
|
|
11
|
+
"line": 1,
|
|
12
|
+
"character": 0,
|
|
13
|
+
"url": "https://github.com/XYOracleNetwork/sdk-xyo-react-js/blob/7efa6fa/packages/theme/src/index.ts#L1"
|
|
14
|
+
}
|
|
15
|
+
]
|
|
7
16
|
}
|
package/package.json
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"dependencies": {
|
|
13
13
|
"@emotion/react": "^11.9.3",
|
|
14
14
|
"@emotion/styled": "^11.9.3",
|
|
15
|
-
"@mui/material": "^5.9.
|
|
15
|
+
"@mui/material": "^5.9.2",
|
|
16
16
|
"lodash": "^4.17.21",
|
|
17
17
|
"react": "^18.2.0",
|
|
18
18
|
"react-dom": "^18.2.0",
|
|
@@ -23,7 +23,7 @@
|
|
|
23
23
|
"@babel/core": "^7.18.9",
|
|
24
24
|
"@babel/preset-env": "^7.18.9",
|
|
25
25
|
"@types/lodash": "^4.14.182",
|
|
26
|
-
"@xylabs/tsconfig": "^
|
|
26
|
+
"@xylabs/tsconfig-dom": "^2.5.3"
|
|
27
27
|
},
|
|
28
28
|
"browser": "dist/esm/index.js",
|
|
29
29
|
"docs": "dist/docs.json",
|
|
@@ -74,5 +74,5 @@
|
|
|
74
74
|
},
|
|
75
75
|
"sideEffects": false,
|
|
76
76
|
"types": "dist/esm/index.d.ts",
|
|
77
|
-
"version": "2.26.
|
|
77
|
+
"version": "2.26.35"
|
|
78
78
|
}
|
package/babel.config.json
DELETED
package/src/appThemeOptions.tsx
DELETED
|
@@ -1,30 +0,0 @@
|
|
|
1
|
-
import { ThemeOptions } from '@mui/material'
|
|
2
|
-
import merge from 'lodash/merge'
|
|
3
|
-
|
|
4
|
-
import { themeOptions } from './themeOptions'
|
|
5
|
-
|
|
6
|
-
const partialAppThemeOptions: ThemeOptions = {
|
|
7
|
-
components: {
|
|
8
|
-
MuiTypography: {
|
|
9
|
-
styleOverrides: {
|
|
10
|
-
root: ({ ownerState }) => {
|
|
11
|
-
const { clamped } = ownerState
|
|
12
|
-
|
|
13
|
-
if (clamped) {
|
|
14
|
-
const maxWidth = parseInt(clamped as string, 10)
|
|
15
|
-
|
|
16
|
-
return {
|
|
17
|
-
overflow: 'hidden',
|
|
18
|
-
textOverflow: 'ellipsis',
|
|
19
|
-
whiteSpace: 'nowrap',
|
|
20
|
-
width: `clamp(1%, 100%, ${maxWidth}px)`,
|
|
21
|
-
}
|
|
22
|
-
}
|
|
23
|
-
},
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
},
|
|
27
|
-
spacing: 8,
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
export const appThemeOptions = merge({}, themeOptions, partialAppThemeOptions)
|
package/src/fontFamily.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export const fontFamilyPrimary = ['Lexend Deca', 'Helvetica', 'sans-serif'].join(',')
|
package/src/index.ts
DELETED
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
import { darken, ThemeOptions } from '@mui/material'
|
|
2
|
-
import merge from 'lodash/merge'
|
|
3
|
-
|
|
4
|
-
const appComponents: ThemeOptions['components'] = {
|
|
5
|
-
MuiPaper: {
|
|
6
|
-
defaultProps: {
|
|
7
|
-
variant: 'elevation',
|
|
8
|
-
},
|
|
9
|
-
},
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export const partialDarkThemeOptions: ThemeOptions = {
|
|
13
|
-
palette: {
|
|
14
|
-
background: {
|
|
15
|
-
default: darken('#171626', 0.1),
|
|
16
|
-
paper: '#171626',
|
|
17
|
-
},
|
|
18
|
-
mode: 'dark',
|
|
19
|
-
primary: {
|
|
20
|
-
main: '#9993F5',
|
|
21
|
-
},
|
|
22
|
-
secondary: {
|
|
23
|
-
main: '#8EC8FF',
|
|
24
|
-
},
|
|
25
|
-
},
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
export const partialAppDarkThemeOptions: ThemeOptions = merge({}, partialDarkThemeOptions, { components: appComponents })
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { ThemeOptions } from '@mui/material'
|
|
2
|
-
import merge from 'lodash/merge'
|
|
3
|
-
|
|
4
|
-
const appComponents: ThemeOptions['components'] = {
|
|
5
|
-
MuiPaper: {
|
|
6
|
-
defaultProps: {
|
|
7
|
-
variant: 'outlined',
|
|
8
|
-
},
|
|
9
|
-
},
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
export const partialLightThemeOptions: ThemeOptions = {
|
|
13
|
-
palette: {
|
|
14
|
-
mode: 'light',
|
|
15
|
-
primary: {
|
|
16
|
-
main: '#1f1a66',
|
|
17
|
-
},
|
|
18
|
-
secondary: {
|
|
19
|
-
main: '#0f68c9',
|
|
20
|
-
},
|
|
21
|
-
},
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export const partialAppLightThemeOptions: ThemeOptions = merge({}, partialLightThemeOptions, { components: appComponents })
|
package/src/themeOptions.ts
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
import { ThemeOptions } from '@mui/material'
|
|
2
|
-
|
|
3
|
-
import { fontFamilyPrimary } from './fontFamily'
|
|
4
|
-
|
|
5
|
-
export const components: ThemeOptions['components'] = {
|
|
6
|
-
MuiCard: {
|
|
7
|
-
styleOverrides: {
|
|
8
|
-
root: {
|
|
9
|
-
display: 'flex',
|
|
10
|
-
flexDirection: 'column',
|
|
11
|
-
justifyContent: 'space-between',
|
|
12
|
-
},
|
|
13
|
-
},
|
|
14
|
-
},
|
|
15
|
-
MuiCardHeader: {
|
|
16
|
-
styleOverrides: {
|
|
17
|
-
content: {
|
|
18
|
-
display: 'flex',
|
|
19
|
-
flexDirection: 'column',
|
|
20
|
-
overflow: 'hidden',
|
|
21
|
-
},
|
|
22
|
-
},
|
|
23
|
-
},
|
|
24
|
-
MuiLink: {
|
|
25
|
-
defaultProps: {
|
|
26
|
-
underline: 'none',
|
|
27
|
-
},
|
|
28
|
-
styleOverrides: {
|
|
29
|
-
root: {
|
|
30
|
-
'&:hover': {
|
|
31
|
-
filter: 'brightness(75%)',
|
|
32
|
-
},
|
|
33
|
-
},
|
|
34
|
-
},
|
|
35
|
-
},
|
|
36
|
-
MuiTableCell: {
|
|
37
|
-
styleOverrides: {
|
|
38
|
-
body: {
|
|
39
|
-
fontFamily: 'monospace',
|
|
40
|
-
whiteSpace: 'nowrap',
|
|
41
|
-
},
|
|
42
|
-
head: {
|
|
43
|
-
fontWeight: 700,
|
|
44
|
-
whiteSpace: 'nowrap',
|
|
45
|
-
},
|
|
46
|
-
},
|
|
47
|
-
},
|
|
48
|
-
}
|
|
49
|
-
|
|
50
|
-
export const typography: ThemeOptions['typography'] = {
|
|
51
|
-
body1: {
|
|
52
|
-
lineHeight: 1.57,
|
|
53
|
-
},
|
|
54
|
-
body2: {
|
|
55
|
-
lineHeight: 1.57,
|
|
56
|
-
},
|
|
57
|
-
button: {
|
|
58
|
-
fontSize: '1rem',
|
|
59
|
-
textTransform: 'inherit',
|
|
60
|
-
},
|
|
61
|
-
fontFamily: fontFamilyPrimary,
|
|
62
|
-
fontWeightBold: 700,
|
|
63
|
-
fontWeightLight: 200,
|
|
64
|
-
fontWeightMedium: 600,
|
|
65
|
-
fontWeightRegular: 400,
|
|
66
|
-
h1: {
|
|
67
|
-
fontFamily: fontFamilyPrimary,
|
|
68
|
-
fontSize: '4rem',
|
|
69
|
-
},
|
|
70
|
-
h2: {
|
|
71
|
-
fontFamily: fontFamilyPrimary,
|
|
72
|
-
fontSize: '2.4rem',
|
|
73
|
-
},
|
|
74
|
-
h3: {
|
|
75
|
-
fontFamily: fontFamilyPrimary,
|
|
76
|
-
fontSize: '2.24rem',
|
|
77
|
-
},
|
|
78
|
-
h4: {
|
|
79
|
-
fontSize: '2rem',
|
|
80
|
-
},
|
|
81
|
-
h5: {
|
|
82
|
-
fontSize: '1.5rem',
|
|
83
|
-
},
|
|
84
|
-
h6: {
|
|
85
|
-
fontSize: '1.25rem',
|
|
86
|
-
},
|
|
87
|
-
subtitle1: {
|
|
88
|
-
opacity: '50%',
|
|
89
|
-
textTransform: 'uppercase',
|
|
90
|
-
},
|
|
91
|
-
subtitle2: {
|
|
92
|
-
opacity: '50%',
|
|
93
|
-
},
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
export const themeOptions: ThemeOptions = {
|
|
97
|
-
components,
|
|
98
|
-
shape: {
|
|
99
|
-
borderRadius: 8,
|
|
100
|
-
},
|
|
101
|
-
spacing: 16,
|
|
102
|
-
typography,
|
|
103
|
-
}
|
package/src/webThemeOptions.tsx
DELETED