@nuskin/foundation-ui-components 1.32.1-cdb-1.2 → 1.32.1-cdb-1.4

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@nuskin/foundation-ui-components",
3
- "version": "1.32.1-cdb-1.2",
3
+ "version": "1.32.1-cdb-1.4",
4
4
  "description": "It is a foundation library written in react, that provides common components to all UI pages",
5
5
  "main": "src/common/index.ts",
6
6
  "repository": {
@@ -26,6 +26,7 @@
26
26
  "build-prod": "yarn build-storybook --mode=production",
27
27
  "build-test": "yarn build-storybook",
28
28
  "build": "next build",
29
+ "build:package": "tsup",
29
30
  "dev": "next dev",
30
31
  "export": "next export",
31
32
  "lint": "next lint",
@@ -46,19 +47,15 @@
46
47
  "@mui/icons-material": "^5.14.16",
47
48
  "@mui/material": "5.14.16",
48
49
  "@mui/utils": "5.14.16",
49
- "@nuskin/foundation-theme": "1.6.0",
50
50
  "@types/react": "^18.2.0",
51
51
  "@types/react-dom": "^18.2.0",
52
52
  "cliui": "^8.0.1",
53
53
  "framer-motion": "^10.16.4",
54
54
  "notistack": "^3.0.1",
55
- "react": "^18.2.0",
56
- "react-dom": "^18.2.0",
57
55
  "react-material-ui-carousel": "^3.4.2",
58
56
  "react-slick": "^0.29.0",
59
57
  "react-window": "^1.8.10",
60
- "slick-carousel": "^1.8.1",
61
- "typescript": "^5.4.2"
58
+ "slick-carousel": "^1.8.1"
62
59
  },
63
60
  "devDependencies": {
64
61
  "@babel/core": "^7.23.2",
@@ -68,6 +65,7 @@
68
65
  "@emotion/jest": "^11.11.0",
69
66
  "next": "13.5.6",
70
67
  "@nuskin/eslint-config": "^1.0.0-setup.1",
68
+ "@nuskin/foundation-theme": "1.7.0-cdb-1.1",
71
69
  "@storybook/addon-actions": "^7.5.1",
72
70
  "@storybook/addon-essentials": "^7.5.1",
73
71
  "@storybook/addon-interactions": "^7.5.1",
@@ -100,10 +98,24 @@
100
98
  "eslint-plugin-storybook": "^0.6.15",
101
99
  "jest": "^29.7.0",
102
100
  "jest-environment-jsdom": "^29.7.0",
103
- "storybook": "^7.5.1"
101
+ "storybook": "^7.5.1",
102
+ "tsup": "8.3.6",
103
+ "typescript": "^5.4.2",
104
+ "react": "^18.2.0",
105
+ "react-dom": "^18.2.0"
106
+ },
107
+ "peerDependencies": {
108
+ "@nuskin/foundation-theme": "1.7.0-cdb-1.1",
109
+ "next": "^13.5.6",
110
+ "react": "^18.2.0",
111
+ "react-dom": "^18.2.0",
112
+ "typescript": "^5.4.2"
104
113
  },
105
114
  "files": [
106
115
  "src/common"
107
116
  ],
117
+ "resolutions": {
118
+ "@emotion/react": "11.11.4"
119
+ },
108
120
  "readme": "./README.md"
109
121
  }
@@ -1,4 +1,5 @@
1
1
  import { Box } from '@mui/material';
2
+ import React from 'react';
2
3
  import { ColorUtils, FoundationTheme, nuskinTheme, styled } from '@nuskin/foundation-theme';
3
4
 
4
5
  import { fieldStateType } from './types.d';
@@ -8,6 +9,7 @@ const { colors } = nuskinTheme;
8
9
 
9
10
  type InputWrapperType = {
10
11
  fieldState: fieldStateType;
12
+ children: React.ReactNode;
11
13
  };
12
14
 
13
15
  const getInputBorderColor = (
@@ -24,7 +26,7 @@ const getInputBorderColor = (
24
26
  }
25
27
  };
26
28
 
27
- const InputWrapper = styled(Box)<InputWrapperType>(({ theme, fieldState }) => {
29
+ const InputWrapper: React.FC<InputWrapperType> = styled(Box)<InputWrapperType>(({ theme, fieldState }) => {
28
30
  /* default value added so that unit tests do not fail */
29
31
  const { palette = { primary: { main: '', contrastText: '' } } } = theme;
30
32
  const isLight = isDarkMode({ theme });