@junyiacademy/ui-test 1.5.12 → 1.5.13

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.
@@ -7,12 +7,12 @@ const styles_1 = require("@mui/material/styles");
7
7
  const material_1 = require("@mui/material");
8
8
  const Button_1 = require("@mui/material/Button");
9
9
  //utils
10
- const lodash_1 = tslib_1.__importDefault(require("lodash"));
10
+ const Capitalize_1 = tslib_1.__importDefault(require("../../utils/Capitalize"));
11
11
  const StyledButton = styles_1.styled(material_1.Button, {
12
12
  shouldForwardProp: (prop) => prop !== 'active',
13
13
  })(({ active, color = 'primary', theme }) => ({
14
14
  // For variant: outlined
15
- [`&.${Button_1.buttonClasses.outlined}${lodash_1.default.capitalize(color)}`]: {
15
+ [`&.${Button_1.buttonClasses.outlined}${Capitalize_1.default(color)}`]: {
16
16
  backgroundColor: active
17
17
  ? theme.palette[color].main
18
18
  : theme.palette.common.white,
@@ -30,7 +30,7 @@ const StyledButton = styles_1.styled(material_1.Button, {
30
30
  },
31
31
  },
32
32
  // For variant: text
33
- [`&.${Button_1.buttonClasses.text}${lodash_1.default.capitalize(color)}`]: {
33
+ [`&.${Button_1.buttonClasses.text}${Capitalize_1.default(color)}`]: {
34
34
  '&:hover': {
35
35
  backgroundColor: styles_1.alpha(theme.palette[color].main, 0.1),
36
36
  },
@@ -7,10 +7,10 @@ const styles_1 = require("@mui/material/styles");
7
7
  const material_1 = require("@mui/material");
8
8
  const ButtonGroup_1 = require("@mui/material/ButtonGroup");
9
9
  //utils
10
- const lodash_1 = tslib_1.__importDefault(require("lodash"));
10
+ const Capitalize_1 = tslib_1.__importDefault(require("../../utils/Capitalize"));
11
11
  // self-defined-components
12
12
  const StyledButtonGroup = styles_1.styled(material_1.ButtonGroup)(({ color = 'primary', theme }) => ({
13
- [`& .${ButtonGroup_1.buttonGroupClasses.groupedOutlined}${lodash_1.default.capitalize(color)}.${ButtonGroup_1.buttonGroupClasses.grouped}.${ButtonGroup_1.buttonGroupClasses.disabled}`]: {
13
+ [`& .${ButtonGroup_1.buttonGroupClasses.groupedOutlined}${Capitalize_1.default(color)}.${ButtonGroup_1.buttonGroupClasses.grouped}.${ButtonGroup_1.buttonGroupClasses.disabled}`]: {
14
14
  borderColor: styles_1.alpha(theme.palette[color].main, 0.5),
15
15
  color: styles_1.alpha(theme.palette[color].main, 0.5),
16
16
  },
@@ -10,7 +10,7 @@ const Input_1 = require("@mui/material/Input");
10
10
  const InputLabel_1 = require("@mui/material/InputLabel");
11
11
  const OutlinedInput_1 = require("@mui/material/OutlinedInput");
12
12
  //utils
13
- const lodash_1 = tslib_1.__importDefault(require("lodash"));
13
+ const Capitalize_1 = tslib_1.__importDefault(require("../../utils/Capitalize"));
14
14
  // self-defined-components
15
15
  const StyledTextField = styles_1.styled(material_1.TextField)(({ label, color = 'primary', theme }) => ({
16
16
  [`& .${InputLabel_1.inputLabelClasses.error}`]: {
@@ -26,7 +26,7 @@ const StyledTextField = styles_1.styled(material_1.TextField)(({ label, color =
26
26
  },
27
27
  // For variant: standard | filled
28
28
  [`& .${Input_1.inputClasses.underline}:not(.${Input_1.inputClasses.disabled})`]: {
29
- [`&.MuiInputBase-color${lodash_1.default.capitalize(color)}:hover:before`]: {
29
+ [`&.MuiInputBase-color${Capitalize_1.default(color)}:hover:before`]: {
30
30
  borderColor: theme.palette[color].main,
31
31
  },
32
32
  },
@@ -38,7 +38,7 @@ const StyledTextField = styles_1.styled(material_1.TextField)(({ label, color =
38
38
  borderColor: theme.palette.error.main,
39
39
  },
40
40
  [`&.${TextField_1.textFieldClasses.root} :not(.${Input_1.inputClasses.disabled}):not(.${Input_1.inputClasses.error})`]: {
41
- [`&.MuiInputBase-color${lodash_1.default.capitalize(color)}:hover .${OutlinedInput_1.outlinedInputClasses.notchedOutline}`]: {
41
+ [`&.MuiInputBase-color${Capitalize_1.default(color)}:hover .${OutlinedInput_1.outlinedInputClasses.notchedOutline}`]: {
42
42
  borderColor: theme.palette[color].main,
43
43
  },
44
44
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@junyiacademy/ui-test",
3
- "version": "1.5.12",
3
+ "version": "1.5.13",
4
4
  "description": "junyiacademy ui library",
5
5
  "main": "./dist/libs/ui/src/index.js",
6
6
  "typings": "./declarations/libs/ui/src/index.d.ts",
@@ -21,7 +21,6 @@
21
21
  "@emotion/styled": "11.6.0",
22
22
  "@mui/icons-material": "5.2.5",
23
23
  "@mui/material": "5.2.7",
24
- "lodash": "^4.17.21",
25
24
  "react": "17.0.2"
26
25
  },
27
26
  "devDependencies": {