Skip to content

Commit bf21756

Browse files
feat: form and form-field with UDS component and Auth0 branding (#35)
* fix: initial commit form-field styling * chore: in progress form-field * feat: add ErrorCircleIcon component and update references in ULThemeFormMessage * style: apply prettier formatting * feat: finalize form field improvements with refactoring * feat: add UL theme form components with comprehensive tests * fix: update README and form-field component for consistency * refactor: rename FormField to FloatingLabelField components
1 parent ffa5f67 commit bf21756

26 files changed

+1452
-543
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -67,11 +67,11 @@ npm install
6767
```bash
6868
# View a specific screen component
6969
# Replace <screen_name> with the desired screen (e.g., login-id, login-password, signup-id)
70-
npm screen <screen_name>
70+
npm run screen <screen_name>
7171

7272
# Examples:
73-
npm screen login-id
74-
npm screen login-password
73+
npm run screen login-id
74+
npm run screen login-password
7575
```
7676

7777
This command loads the specified screen component with its corresponding mock data (e.g., `src/mock-data/login-id.json`) in your browser for local development. The `scripts/dev-screen.js` utility handles setting the `VITE_SCREEN_NAME` environment variable, which `src/utils/screen/mockContextLoader.ts` uses to inject the correct mock context.
@@ -97,7 +97,7 @@ Each screen component is designed to be used with the Auth0 ACUL JavaScript SDK
9797
For local development, each screen component is provided with mock data in folder `mock-data` for sdk to render screens. To work on a specific screen:
9898

9999
```bash
100-
npm screen <screen_name>
100+
npm run screen <screen_name>
101101
```
102102

103103
This command, managed by `scripts/dev-screen.js`:

eslint.config.js

Lines changed: 13 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,7 @@ export default tseslint.config(
4141

4242
rules: {
4343
// Run Prettier as an ESLint rule and report formatting issues as errors
44-
"prettier/prettier": [
45-
"error",
46-
{
47-
endOfLine: "auto", // Prevents false positives for line endings
48-
},
49-
],
44+
"prettier/prettier": "error",
5045
...reactHooks.configs.recommended.rules,
5146
"react-refresh/only-export-components": [
5247
"warn",
@@ -75,6 +70,18 @@ export default tseslint.config(
7570
},
7671
},
7772

73+
// Test file overrides - allow more relaxed rules for test files
74+
{
75+
files: [
76+
"**/__tests__/**/*.{ts,tsx}",
77+
"**/*.test.{ts,tsx}",
78+
"**/*.spec.{ts,tsx}",
79+
],
80+
rules: {
81+
"@typescript-eslint/no-explicit-any": "off", // Allow 'any' type in tests for simplicity
82+
},
83+
},
84+
7885
// Disables all formatting rules that conflict with Prettier. Must be last.
7986
eslintConfigPrettier
8087
);

0 commit comments

Comments
 (0)