@learningpool/ui 1.3.0-beta.3 → 1.4.0
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.
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { makeStyles } from 'tss-react/mui';
|
|
2
|
+
export var AvatarStyles = makeStyles()(function (theme, props) {
|
|
3
|
+
var _a, _b, _c;
|
|
4
|
+
return ({
|
|
5
|
+
root: {
|
|
6
|
+
backgroundColor: ((_a = props === null || props === void 0 ? void 0 : props.sx) === null || _a === void 0 ? void 0 : _a.bgcolor)
|
|
7
|
+
? props.sx.bgcolor
|
|
8
|
+
: theme.palette.primary.main,
|
|
9
|
+
color: ((_b = props === null || props === void 0 ? void 0 : props.sx) === null || _b === void 0 ? void 0 : _b.bgcolor)
|
|
10
|
+
? (_c = props.sx.color) !== null && _c !== void 0 ? _c : theme.palette.getContrastText(props.sx.bgcolor)
|
|
11
|
+
: theme.palette.primary.contrastText
|
|
12
|
+
}
|
|
13
|
+
});
|
|
14
|
+
});
|
|
@@ -133,11 +133,11 @@ var VerticalNavigation = function (props) {
|
|
|
133
133
|
} }, { children: _jsx(AppSwitcher, { apiKey: (_b = (_a = process === null || process === void 0 ? void 0 : process.env) === null || _a === void 0 ? void 0 : _a.REACT_APP_STREAM_HOME_API_KEY) !== null && _b !== void 0 ? _b : '7wxswYRq238tj65RVina32VSzmpGamju7Edvbrab', baseUrl: (_d = (_c = process === null || process === void 0 ? void 0 : process.env) === null || _c === void 0 ? void 0 : _c.REACT_APP_STREAM_HOME_API_URL) !== null && _d !== void 0 ? _d : 'https://6cqjg9ua08.execute-api.us-east-1.amazonaws.com/dev-api', token: 'hfcfgcgfcgfhcfhgcfg' }) })), _jsx(ListItemText, { primary: 'App switcher', sx: { opacity: isDrawerOpen ? 1 : 0 } })] })) })))
|
|
134
134
|
: null, secondaryItems === null || secondaryItems === void 0 ? void 0 : secondaryItems.map(function (item, index) {
|
|
135
135
|
var _a;
|
|
136
|
-
return (_jsx(ListItem, { children: _jsxs(ListItemButton
|
|
136
|
+
return (_jsx(ListItem, __assign({ disablePadding: true }, { children: _jsxs(ListItemButton
|
|
137
137
|
// @ts-expect-error
|
|
138
138
|
, __assign({
|
|
139
139
|
// @ts-expect-error
|
|
140
|
-
component: Link, onClick: item.onClick, isActive: item.isActive }, { children: [_jsx(ListItemIcon, { children: (_a = item.icon) !== null && _a !== void 0 ? _a : _jsx(MailIcon, {}) }), _jsx(ListItemText, { primary: item.label })] }), item.label) }));
|
|
140
|
+
component: Link, onClick: item.onClick, isActive: item.isActive }, { children: [_jsx(ListItemIcon, { children: (_a = item.icon) !== null && _a !== void 0 ? _a : _jsx(MailIcon, {}) }), _jsx(ListItemText, { primary: item.label })] }), item.label) })));
|
|
141
141
|
}), _jsx(ListItem, __assign({ disablePadding: true }, { children: _jsxs(ListItemAvatar
|
|
142
142
|
// @ts-expect-error
|
|
143
143
|
, __assign({
|
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@learningpool/ui",
|
|
3
3
|
"author": "Learning Pool",
|
|
4
|
+
"description": "UI library for use on modern Learning Pool projects, built on top of MUI.",
|
|
4
5
|
"license": "MIT",
|
|
5
6
|
"keywords": [
|
|
6
7
|
"learning-pool",
|
|
@@ -8,14 +9,10 @@
|
|
|
8
9
|
"components",
|
|
9
10
|
"ui"
|
|
10
11
|
],
|
|
11
|
-
"version": "1.
|
|
12
|
+
"version": "1.4.0",
|
|
12
13
|
"private": false,
|
|
13
14
|
"main": "dist/index.js",
|
|
14
15
|
"module": "dist/index.js",
|
|
15
|
-
"peerDependencies": {
|
|
16
|
-
"react": ">=17.0.2",
|
|
17
|
-
"react-dom": ">=17.0.2"
|
|
18
|
-
},
|
|
19
16
|
"dependencies": {
|
|
20
17
|
"@emotion/react": "^11.7.1",
|
|
21
18
|
"@emotion/styled": "^11.6.0",
|
|
@@ -31,7 +28,9 @@
|
|
|
31
28
|
"@types/react-dom": "^17.0.11",
|
|
32
29
|
"anysort": "^2.0.0",
|
|
33
30
|
"focus-trap-react": "^8.11.0",
|
|
34
|
-
"react
|
|
31
|
+
"react": "^17.0.2",
|
|
32
|
+
"react-dom": "^17.0.2",
|
|
33
|
+
"react-scripts": "5.0.1",
|
|
35
34
|
"tss-react": "^3.3.6",
|
|
36
35
|
"typescript": "^4.6.2",
|
|
37
36
|
"web-vitals": "^2.1.4"
|
|
@@ -40,7 +39,8 @@
|
|
|
40
39
|
"analyze:build": "source-map-explorer 'build/static/js/*.js'",
|
|
41
40
|
"analyze:module": "source-map-explorer 'dist/*.js'",
|
|
42
41
|
"build": "build-storybook",
|
|
43
|
-
"build:module": "rm -rf dist && yarn run tsc",
|
|
42
|
+
"build:module": "rm -rf dist && yarn run tsc && yarn run generate:package",
|
|
43
|
+
"generate:package": "node ./merge.js",
|
|
44
44
|
"lint": "eslint --ext .tsx ./src",
|
|
45
45
|
"lint:fix": "eslint --ext .tsx ./src --fix",
|
|
46
46
|
"semantic-release": "ht2-release-public-circleci-lib-dist",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"@babel/preset-env": "7.16.11",
|
|
70
70
|
"@babel/preset-react": "7.16.7",
|
|
71
71
|
"@babel/preset-typescript": "7.16.7",
|
|
72
|
-
"@ht2-labs/semantic-release": "
|
|
72
|
+
"@ht2-labs/semantic-release": "3.0.0",
|
|
73
73
|
"@storybook/addon-a11y": "6.5.6",
|
|
74
74
|
"@storybook/addon-actions": "6.5.6",
|
|
75
75
|
"@storybook/addon-essentials": "6.5.6",
|
|
@@ -82,15 +82,15 @@
|
|
|
82
82
|
"@storybook/preset-create-react-app": "4.1.1",
|
|
83
83
|
"@storybook/react": "6.5.6",
|
|
84
84
|
"@storybook/theming": "6.5.6",
|
|
85
|
-
"babel-preset-minify": "0.5.
|
|
85
|
+
"babel-preset-minify": "0.5.2",
|
|
86
86
|
"eslint-config-standard": "16.0.3",
|
|
87
87
|
"eslint-config-standard-with-typescript": "21.0.1",
|
|
88
88
|
"eslint-plugin-node": "11.1.0",
|
|
89
89
|
"eslint-plugin-promise": "6.0.0",
|
|
90
90
|
"source-map-explorer": "2.5.2",
|
|
91
91
|
"source-map-loader": "3.0.1",
|
|
92
|
-
"ts-node": "10.
|
|
93
|
-
"webpack": "5.
|
|
92
|
+
"ts-node": "10.8.0",
|
|
93
|
+
"webpack": "5.72.1"
|
|
94
94
|
},
|
|
95
95
|
"release": {
|
|
96
96
|
"branches": [
|
package/readme.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# @learningpool/ui
|
|
2
2
|
|
|
3
3
|

|
|
4
|
+

|
|
4
5
|

|
|
5
6
|

|
|
6
7
|

|