diff --git a/frontend/src/layouts/MainLayout/components/UserProfileActions.jsx b/frontend/src/layouts/MainLayout/components/UserProfileActions.jsx index f5f7dbc68..37ebd0557 100644 --- a/frontend/src/layouts/MainLayout/components/UserProfileActions.jsx +++ b/frontend/src/layouts/MainLayout/components/UserProfileActions.jsx @@ -38,7 +38,6 @@ export const UserProfileActions = () => { refetchInterval: 60000 // Automatically refetch every 1 minute (60000ms) }) const notificationsCount = notificationsData?.count || 0 - console.log(notificationsData) // Call refetch whenever the route changes useEffect(() => { diff --git a/frontend/src/views/Transactions/components/TransactionDetails.jsx b/frontend/src/views/Transactions/components/TransactionDetails.jsx index 0c3b51199..81fdd1b3b 100644 --- a/frontend/src/views/Transactions/components/TransactionDetails.jsx +++ b/frontend/src/views/Transactions/components/TransactionDetails.jsx @@ -244,8 +244,11 @@ export const TransactionDetails = ({ transactionId, isEditable }) => { helperText={errors.complianceUnits?.message} value={formattedValue} onChange={(e) => { - // Remove all non-digit characters - const numericValue = e.target.value.replace(/\D/g, '') + // Remove all non-digit characters (other than - at the front) + const numericValue = e.target.value.replace( + /(?!^-)[^0-9]/g, + '' + ) // Update the form state with the raw number onChange(numericValue) }}