Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Vertical stepper implemenetation #1441
Vertical stepper implemenetation #1441
Changes from 4 commits
fe9341f
70aab30
d9525f3
d631f37
c12d9eb
8e22724
6c05bf1
bcce31b
b720036
ef7e850
d1d493e
a8787a5
e1c207f
b30cc19
0ad275f
f580d17
12d71e6
a1c5dc2
253e2cb
f372b96
22e3bc4
941ea96
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wrap error message with translation function
The error message
'HCM_FILE_UNAVAILABLE'
should be wrapped with thet()
function to support internationalization, consistent with other error messages.Apply the following diff:
📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🛠️ Refactor suggestion
Handle FileReader errors
The
FileReader
currently lacks error handling for file read errors. Adding anonerror
handler will improve robustness by properly managing read errors.Add the following code:
Ensure that the translation key
HCM_FILE_READING_ERROR
is added to your localization files.📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Enable file validation in
handleChange
functionThe call to
validateExcel
is currently commented out, which means uploaded files are not being validated. To ensure that only valid files are processed, consider uncommenting this line.Apply the following diff:
📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Improve accessibility by adding keyboard event handlers
The
div
element at lines 128-135 has anonClick
handler but lacks corresponding keyboard event handlers. This can hinder accessibility for users who navigate via keyboard. Consider addingonKeyDown
oronKeyUp
event handlers and setting thetabIndex
androle
attributes to make the element focusable and operable with the keyboard.Apply the following diff to enhance accessibility:
📝 Committable suggestion
🧰 Tools
🪛 Biome
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick (assertive)
Clean up commented-out code
The commented-out
onClick
handler is not needed if it's not intended for future use. Removing it can help keep the code clean.Apply the following diff:
📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Avoid passing children via props
Passing
children
as a prop is not recommended. Instead, the standard practice in React is to nest child elements directly within the component's JSX.Apply the following diff to refactor the code:
📝 Committable suggestion
🧰 Tools
🪛 Biome
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick (assertive)
Remove unused commented-out code
The commented-out
error
prop in the<Toast>
component is unnecessary and can be removed to declutter the code.Apply the following diff:
- // error={showToast?.key === "error" ? true : false}
📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Fix typo in prop name
There's a typo in the prop
isDleteBtn
. It should beisDeleteBtn
to ensure the property functions correctly.Apply the following diff:
📝 Committable suggestion
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🧹 Nitpick (assertive)
Simplify JSX by using self-closing elements
The
<Toast>
component does not contain any children and can be self-closed for cleaner syntax.Apply the following diff:
📝 Committable suggestion
🧰 Tools
🪛 Biome