Closed zed-wong closed 2 months ago
The latest updates on your projects. Learn more about Vercel for Git ↗︎
Name | Status | Preview | Comments | Updated (UTC) |
---|---|---|---|---|
mr-market | ✅ Ready (Inspect) | Visit Preview | 💬 Add feedback | Apr 17, 2024 9:16am |
This PR is being deployed to Railway 🚅
This PR is being deployed to Railway 🚅
Mr.Market: ◻️ REMOVED
PR Description updated to latest commit (https://github.com/Hu-Fi/Mr.Market/commit/7d14c549cab27cd243e396e87ff52e360ef2dff8)
⏱️ Estimated effort to review [1-5] | 2, because the changes are straightforward and limited to adding an attribute to input fields across several files. The logic and structure of the code remain unchanged, making it easier to review. |
🧪 Relevant tests | No |
🔍 Possible issues | Inconsistent Attribute Order: In some files, the `inputmode="decimal"` attribute is added before the `type="tel"` attribute, while in others, it is added after. Consistency in attribute order can improve readability and maintainability. |
🔒 Security concerns | No |
relevant file | interface/src/lib/components/grow/arbitrage/new/easy/exchanges.svelte |
suggestion | Consider maintaining a consistent order of attributes in your HTML tags for better readability. For instance, always place `inputmode` after `type`. [medium] |
relevant line | inputmode="decimal" |
PR Description updated to latest commit (https://github.com/Hu-Fi/Mr.Market/commit/7d14c549cab27cd243e396e87ff52e360ef2dff8)
Persistent review updated to latest commit https://github.com/Hu-Fi/Mr.Market/commit/7d14c549cab27cd243e396e87ff52e360ef2dff8
Category | Suggestions |
Best practice |
Add input validation to ensure correct decimal values.___ **Consider adding error handling or validation for the input fields to ensure that thevalues entered are within expected ranges or formats, especially since the input mode is set to decimal.** [interface/src/lib/components/grow/marketMaking/new/easy/amount.svelte [35]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-459a25a5ea5b96b0229135f3d0cef5dfc4bb8b073efd3be20b13d92890eade55R35-R35) ```diff - + ``` |
Ensure that the input mask configuration supports decimal formatting.___ **Since the input mode is set to decimal, ensure that the cleave.js configuration( maskOption ) properly handles decimal inputs, including appropriate decimal separators and number formatting.** [interface/src/lib/components/swap/input.svelte [83-87]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-3ebcc855afc26c1448e6d2669f19afae0350fd0aa75f427f7be8dc6478622973R83-R87) ```diff | |
Accessibility |
Improve accessibility by adding aria-labels to inputs.___ **To improve accessibility and user experience, consider adding labels or aria-labels toinputs, especially when changing input modes to support screen readers and assistive technologies.** [interface/src/lib/components/spot/bids/inputs.svelte [199-203]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-12445a9b778b968349e9b5aa908c04ef41c20d7fa6f232d972fb3e936a93bfd0R199-R203) ```diff |
Enhancement |
Implement rounding/formatting of output values to enhance data integrity.___ **To prevent potential user errors and enhance data integrity, consider implementing amechanism to round or format the output values to a specified number of decimal places.** [interface/src/lib/components/swap/output.svelte [83-87]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-9ddd5334cd6d09b1881f372f5c1a41de1af7fa031abbbe1eb6a429f977037b35R83-R87) ```diff |
Category | Suggestions |
Best practice |
Add validation for decimal inputs to ensure data integrity.___ **Consider adding error handling or validation for the input fields whereinputmode="decimal" is used, to ensure that the input is correctly formatted and valid before processing.** [interface/src/lib/components/spot/bids/inputs.svelte [199-203]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-12445a9b778b968349e9b5aa908c04ef41c20d7fa6f232d972fb3e936a93bfd0R199-R203) ```diff |
Accessibility |
Improve accessibility by adding descriptive labels to inputs.___ **To enhance accessibility, consider addingaria-label or aria-labelledby attributes to inputs with inputmode="decimal" to provide a clear description of the input's purpose for screen readers.** [interface/src/lib/components/swap/input.svelte [82-87]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-3ebcc855afc26c1448e6d2669f19afae0350fd0aa75f427f7be8dc6478622973R82-R87) ```diff |
Maintainability |
Enhance responsiveness of input elements across devices.___ **To prevent potential layout issues on different devices, consider adding responsive CSSclasses or styles to the input elements to ensure they render correctly across all screen sizes.** [interface/src/lib/components/swap/output.svelte [82-87]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-9ddd5334cd6d09b1881f372f5c1a41de1af7fa031abbbe1eb6a429f977037b35R82-R87) ```diff |
Security |
Add user confirmation for critical financial inputs.___ **Since the input fields are critical for financial transactions, consider implementing aconfirmation step or additional user verification before processing the input to enhance security.** [interface/src/lib/components/grow/marketMaking/new/easy/amount.svelte [34-35]](https://github.com/Hu-Fi/Mr.Market/pull/158/files#diff-459a25a5ea5b96b0229135f3d0cef5dfc4bb8b073efd3be20b13d92890eade55R34-R35) ```diff |
Type
bug_fix, enhancement
Description
inputmode="decimal"
attribute to various input fields across multiple components to fix and enhance numeric input handling on iOS devices.Changes walkthrough
exchanges.svelte
Enhance Numeric Input for iOS in Arbitrage Exchanges Component
interface/src/lib/components/grow/arbitrage/new/easy/exchanges.svelte
inputmode="decimal"
to the input field to enhance numeric inputon iOS devices.
amount.svelte
Enhance Numeric Input for iOS in Market Making Amount Component
interface/src/lib/components/grow/marketMaking/new/easy/amount.svelte
inputmode="decimal"
to two input fields to ensure proper numericinput on iOS.
inputs.svelte
Enhance Numeric Input for iOS in Spot Bids Inputs Component
interface/src/lib/components/spot/bids/inputs.svelte
inputmode="decimal"
to multiple input fields to improve numericinput handling on iOS.
input.svelte
Enhance Numeric Input for iOS in Swap Input Component
interface/src/lib/components/swap/input.svelte
inputmode="decimal"
to the input field to facilitate numericinput on iOS.
output.svelte
Enhance Numeric Input for iOS in Swap Output Component
interface/src/lib/components/swap/output.svelte
inputmode="decimal"
to the output field to improve numeric inputon iOS.