@corva/create-app 0.14.0-rc.0 → 0.15.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.
- package/CHANGELOG.md +18 -1
- package/package.json +1 -1
- package/template/ui/ts/.eslintrc +7 -1
- package/template/ui/ts/src/AppSettings.tsx +14 -25
package/CHANGELOG.md
CHANGED
|
@@ -2,7 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
|
|
4
4
|
|
|
5
|
-
## [0.
|
|
5
|
+
## [0.15.0](https://github.com/corva-ai/create-corva-app/compare/v0.15.0-rc.0...v0.15.0) (2021-11-24)
|
|
6
|
+
|
|
7
|
+
## [0.15.0-rc.0](https://github.com/corva-ai/create-corva-app/compare/v0.15.0-0...v0.15.0-rc.0) (2021-11-09)
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
### Features
|
|
11
|
+
|
|
12
|
+
* **core:** upgrade template AppSettings.tsx to React.FC approach ([383203c](https://github.com/corva-ai/create-corva-app/commit/383203c5d4323f66218726de16be0a77da108f7e))
|
|
13
|
+
|
|
14
|
+
|
|
15
|
+
### Bug Fixes
|
|
16
|
+
|
|
17
|
+
* **templates:** move out React.FC syntax from AppSettings.tsx ([aaec071](https://github.com/corva-ai/create-corva-app/commit/aaec071cf5c546c226ad59133b5d28b29e968f58))
|
|
18
|
+
|
|
19
|
+
## [0.15.0-0](https://github.com/corva-ai/create-corva-app/compare/v0.14.0-0...v0.15.0-0) (2021-10-26)
|
|
6
20
|
|
|
7
21
|
## [0.14.0-0](https://github.com/corva-ai/create-corva-app/compare/v0.13.0-0...v0.14.0-0) (2021-10-12)
|
|
8
22
|
|
|
@@ -138,6 +152,9 @@ All notable changes to this project will be documented in this file. See [standa
|
|
|
138
152
|
## [0.6.0-0](https://github.com/facebook/create-react-app/compare/v0.5.0-0...v0.6.0-0) (2021-06-16)
|
|
139
153
|
|
|
140
154
|
## [0.5.0-0](https://github.com/facebook/create-react-app/compare/v0.2.29...v0.5.0-0) (2021-06-02)
|
|
155
|
+
## [0.4.0](https://github.com/facebook/create-react-app/compare/v0.4.0-rc.0...v0.4.0) (2021-06-16)
|
|
156
|
+
|
|
157
|
+
## [0.4.0-rc.0](https://github.com/facebook/create-react-app/compare/v0.2.29...v0.4.0-rc.0) (2021-06-02)
|
|
141
158
|
|
|
142
159
|
### [0.4.3](https://github.com/facebook/create-react-app/compare/v0.4.0...v0.4.3) (2021-05-26)
|
|
143
160
|
|
package/package.json
CHANGED
package/template/ui/ts/.eslintrc
CHANGED
|
@@ -10,6 +10,12 @@
|
|
|
10
10
|
"extends": ["@corva/eslint-config-browser", "plugin:@typescript-eslint/recommended"],
|
|
11
11
|
"rules": {
|
|
12
12
|
"react/jsx-filename-extension": [1, { "extensions": [".js", ".jsx", ".ts", ".tsx"] }],
|
|
13
|
-
"@typescript-eslint/no-explicit-any": "off"
|
|
13
|
+
"@typescript-eslint/no-explicit-any": "off",
|
|
14
|
+
/* Turned off until adopted by @corva/eslint-config-browser */
|
|
15
|
+
"react/prop-types": 0,
|
|
16
|
+
"react/default-props-match-prop-types": 0,
|
|
17
|
+
"react/no-unused-prop-types": 0,
|
|
18
|
+
"react/require-default-props": 0
|
|
19
|
+
/* Turned off until adopted by @corva/eslint-config-browser */
|
|
14
20
|
}
|
|
15
21
|
}
|
|
@@ -1,20 +1,9 @@
|
|
|
1
1
|
import { Checkbox, FormControlLabel } from '@material-ui/core';
|
|
2
|
-
import PropTypes from 'prop-types';
|
|
3
2
|
|
|
4
3
|
import { DEFAULT_SETTINGS } from './constants';
|
|
5
4
|
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
appData: { [key: string]: any };
|
|
9
|
-
company: { [key: string]: any };
|
|
10
|
-
onSettingChange: (key: string, value: any) => void;
|
|
11
|
-
settings: {
|
|
12
|
-
isExampleCheckboxChecked: boolean;
|
|
13
|
-
};
|
|
14
|
-
user: { [key: string]: any };
|
|
15
|
-
};
|
|
16
|
-
|
|
17
|
-
function AppSettings({ settings: apiSettings, onSettingChange }: Props): JSX.Element {
|
|
5
|
+
const AppSettings = (props: AppSettingsProps): JSX.Element => {
|
|
6
|
+
const { settings: apiSettings, onSettingChange } = props;
|
|
18
7
|
const settings = { ...DEFAULT_SETTINGS, ...apiSettings };
|
|
19
8
|
|
|
20
9
|
return (
|
|
@@ -30,24 +19,24 @@ function AppSettings({ settings: apiSettings, onSettingChange }: Props): JSX.Ele
|
|
|
30
19
|
/>
|
|
31
20
|
</div>
|
|
32
21
|
);
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
AppSettings.propTypes = {
|
|
36
|
-
app: PropTypes.shape({}).isRequired,
|
|
37
|
-
appData: PropTypes.shape({}).isRequired,
|
|
38
|
-
company: PropTypes.shape({}),
|
|
39
|
-
onSettingChange: PropTypes.func.isRequired,
|
|
40
|
-
settings: PropTypes.shape({
|
|
41
|
-
isExampleCheckboxChecked: PropTypes.bool,
|
|
42
|
-
}).isRequired,
|
|
43
|
-
user: PropTypes.shape({}),
|
|
44
22
|
};
|
|
45
|
-
|
|
46
23
|
AppSettings.defaultProps = {
|
|
47
24
|
user: {},
|
|
48
25
|
company: {},
|
|
49
26
|
};
|
|
50
27
|
|
|
28
|
+
/* Types */
|
|
29
|
+
interface AppSettingsProps {
|
|
30
|
+
app: { [key: string]: any };
|
|
31
|
+
appData: { [key: string]: any };
|
|
32
|
+
company: { [key: string]: any };
|
|
33
|
+
onSettingChange: (key: string, value: any) => void;
|
|
34
|
+
settings: {
|
|
35
|
+
isExampleCheckboxChecked: boolean;
|
|
36
|
+
};
|
|
37
|
+
user: { [key: string]: any };
|
|
38
|
+
}
|
|
39
|
+
|
|
51
40
|
// Important: Do not change root component default export (AppSettings.js). Use it as container
|
|
52
41
|
// for your App Settings. It's required to make build and zip scripts work as expected;
|
|
53
42
|
export default AppSettings;
|