Skip to content

Commit 47b3f90

Browse files
Merge branch 'dev' into UDS-2010-A
2 parents ef23c3f + 84d5b70 commit 47b3f90

File tree

22 files changed

+206
-129
lines changed

22 files changed

+206
-129
lines changed

eslint.config.js

Lines changed: 27 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ const js = require("@eslint/js");
77
const importPlugin = require("eslint-plugin-import");
88
const jsxA11y = require("eslint-plugin-jsx-a11y");
99
const prettier = require("eslint-plugin-prettier");
10+
const eslintPluginPrettier = require("eslint-config-prettier");
11+
const eslintPluginReactHooks = require("eslint-plugin-react-hooks");
1012

1113
module.exports = [
1214
js.configs.recommended,
@@ -31,6 +33,8 @@ module.exports = [
3133
import: importPlugin,
3234
"jsx-a11y": jsxA11y,
3335
prettier,
36+
eslintPluginPrettier,
37+
"react-hooks": eslintPluginReactHooks,
3438
},
3539
settings: {
3640
react: {
@@ -51,6 +55,12 @@ module.exports = [
5155
"react/jsx-no-useless-fragment": "off",
5256
"react/require-default-props": "off",
5357
"react/jsx-props-no-spreading": "off",
58+
"react/jsx-uses-vars": "error", // Marks JSX variables as used
59+
"react/jsx-uses-react": "error", // Marks React as used in JSX files
60+
61+
// React Hooks rules
62+
"react-hooks/rules-of-hooks": "error",
63+
"react-hooks/exhaustive-deps": "warn",
5464

5565
// Import rules
5666
"import/no-relative-packages": "off",
@@ -74,7 +84,8 @@ module.exports = [
7484
"no-console": 1,
7585
"no-unused-vars": ["warn", {
7686
argsIgnorePattern: "^_",
77-
varsIgnorePattern: "^(React|_)",
87+
varsIgnorePattern: "^(React|_|expect|test|describe|it|beforeEach|afterEach|beforeAll|afterAll|jest|vi|fixture|page)$",
88+
ignoreRestSiblings: true,
7889
}],
7990
"no-undef": "off", // Disable for config files and test files
8091

@@ -110,6 +121,7 @@ module.exports = [
110121
import: importPlugin,
111122
"jsx-a11y": jsxA11y,
112123
prettier,
124+
"react-hooks": eslintPluginReactHooks,
113125
},
114126
settings: {
115127
react: {
@@ -141,11 +153,16 @@ module.exports = [
141153
extensions: [".js", ".jsx", ".ts", ".tsx"],
142154
}],
143155
"@typescript-eslint/ban-ts-comment": ["warn"],
144-
"no-unused-vars": "off",
156+
"no-unused-vars": ["warn", {
157+
argsIgnorePattern: "^_",
158+
varsIgnorePattern: "^(React|_|expect|test|describe|it|beforeEach|afterEach|beforeAll|afterAll|jest|vi|fixture|page)$",
159+
ignoreRestSiblings: true,
160+
}],
145161
"react/require-default-props": "off",
146-
"@typescript-eslint/no-unused-vars": ["error", {
162+
"@typescript-eslint/no-unused-vars": ["warn", {
147163
argsIgnorePattern: "^_",
148-
varsIgnorePattern: "^(React|_)",
164+
varsIgnorePattern: "^(React|_|expect|test|describe|it|beforeEach|afterEach|beforeAll|afterAll|jest|vi|fixture|page)$",
165+
ignoreRestSiblings: true,
149166
}],
150167
"@typescript-eslint/no-empty-function": "off",
151168

@@ -160,6 +177,12 @@ module.exports = [
160177
"no-promise-executor-return": "off",
161178
"default-param-last": "off",
162179
"react/jsx-props-no-spreading": "off",
180+
"react/jsx-uses-vars": "error", // Marks JSX variables as used
181+
"react/jsx-uses-react": "error", // Marks React as used in JSX files
182+
183+
// React Hooks rules
184+
"react-hooks/rules-of-hooks": "error",
185+
"react-hooks/exhaustive-deps": "warn",
163186
"prettier/prettier": ["error", {}, {
164187
usePrettierrc: true,
165188
}],

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,12 +77,12 @@
7777
"eslint": "^9",
7878
"eslint-config-prettier": "^8.2.0",
7979
"eslint-plugin-import": "^2.22.1",
80-
"eslint-plugin-import-helpers": "^1.1.0",
80+
"eslint-plugin-import-helpers": "^2",
8181
"eslint-plugin-jest": "^28",
8282
"eslint-plugin-jsx-a11y": "^6.10.2",
8383
"eslint-plugin-prettier": "^5.5.1",
8484
"eslint-plugin-react": "^7.37.4",
85-
"eslint-plugin-react-hooks": "^4",
85+
"eslint-plugin-react-hooks": "^5",
8686
"eslint-plugin-storybook": "^9.0.13",
8787
"gh-pages": "^6.0.0",
8888
"globals": "^16.2.0",
@@ -93,7 +93,7 @@
9393
"mini-css-extract-plugin": "^2.0.0",
9494
"nunjucks": "^3.2.0",
9595
"playwright": "1.50.1",
96-
"prettier": "^2.2.1",
96+
"prettier": "^3",
9797
"purgecss-webpack-plugin": "^4.0.3",
9898
"react": "^18.3.1",
9999
"react-dom": "^18.3.1",

packages/app-rfi/src/components/AsuRfi/index.js

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -63,10 +63,6 @@ const AsuRfi = props => {
6363
}
6464
}, []);
6565

66-
if (typeof submissionUrl === "undefined") {
67-
return <></>;
68-
}
69-
7066
const rfiState = useRfiState(betterPropNames(props));
7167

7268
const noRfiAvailable = `RFI form not displayed. ${programOfInterest} has rfiDisplay set to false or does not exist`;
@@ -75,6 +71,11 @@ const AsuRfi = props => {
7571
console.log(noRfiAvailable);
7672
}
7773
}, [rfiState.showForm]);
74+
75+
if (typeof submissionUrl === "undefined") {
76+
return <></>;
77+
}
78+
7879
if (!rfiState.showForm) {
7980
return <div style={{ display: "none" }}>{noRfiAvailable}</div>;
8081
}

packages/app-rfi/src/components/controls/RfiSelect.js

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,4 @@
11
// DISABLED@ts-check
2-
/* eslint-disable no-unused-vars */
32

43
import { Field, useField, useFormikContext } from "formik";
54
import PropTypes from "prop-types";

packages/app-webdir-ui/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
# [@asu/app-webdir-ui-v5.0.4](https://github.com/asu/asu-unity-stack/compare/@asu/app-webdir-ui-v5.0.3...@asu/app-webdir-ui-v5.0.4) (2025-07-24)
2+
3+
4+
### Bug Fixes
5+
6+
* **app-webdir-ui:** add @asu/shared to dependencies ([b41a445](https://github.com/asu/asu-unity-stack/commit/b41a44540c5b2a28e070cebcc93413b0b7b63160))
7+
18
# [@asu/app-webdir-ui-v5.0.3](https://github.com/asu/asu-unity-stack/compare/@asu/app-webdir-ui-v5.0.2...@asu/app-webdir-ui-v5.0.3) (2025-03-12)
29

310

packages/app-webdir-ui/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@asu/app-webdir-ui",
3-
"version": "5.0.3",
3+
"version": "5.0.4",
44
"description": "App Webdir UI",
55
"main": "./dist/webdirUI.cjs.js",
66
"browser": "./dist/webdirUI.umd.js",

packages/component-header-footer/CHANGELOG.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
1+
# [@asu/component-header-footer-v1.0.13](https://github.com/asu/asu-unity-stack/compare/@asu/component-header-footer-v1.0.12...@asu/component-header-footer-v1.0.13) (2025-07-24)
2+
3+
4+
### Bug Fixes
5+
6+
* **component-header-footer:** fix social icon focus styles ([f58b6bb](https://github.com/asu/asu-unity-stack/commit/f58b6bb3e617c1c12ca9ed9d9b2a8f4e7ba4cfb2))
7+
18
# [@asu/component-header-footer-v1.0.12](https://github.com/asu/asu-unity-stack/compare/@asu/component-header-footer-v1.0.11...@asu/component-header-footer-v1.0.12) (2025-07-14)
29

310

packages/component-header-footer/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@asu/component-header-footer",
3-
"version": "1.0.12",
3+
"version": "1.0.13",
44
"description": "ASU Global Header and Footer",
55
"main": "./dist/asuHeaderFooter.cjs.js",
66
"browser": "./dist/asuHeaderFooter.umd.js",

packages/component-header-footer/src/footer/index.styles.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -170,7 +170,7 @@ const StyledFooter = styled.footer`
170170
171171
&:last-child {
172172
@media (min-width: 768px) {
173-
padding-right: 0;
173+
/* padding-right: 0; */
174174
}
175175
}
176176
}

packages/shared/assets/index.js

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,6 @@
11
import * as _images from "./img/list";
22
export { imageName } from "./img/named";
33

4-
const _imageArray = Object.values(_images).reduce(
5-
(result, val) => [...result, val.default],
6-
[]
7-
);
8-
9-
export const imageArray = [
10-
..._imageArray,
11-
..._imageArray,
12-
..._imageArray,
13-
..._imageArray,
14-
..._imageArray,
15-
]; // make it bigger
4+
export const imageArray = Object.values(_images);
165
export const imageAny = () =>
176
imageArray[Math.floor(Math.random() * imageArray.length)];

0 commit comments

Comments
 (0)