mirror of
https://github.com/mauriceboe/TREK.git
synced 2026-12-02 01:12:16 +00:00
fix(quality): resolve reliability findings on dev
The Sonar quality gate rated new code D. Preserve focus and keyboard interaction through native controls and shared dialog behavior. Replace ambiguous regex scans with bounded parsing and make numeric coercion and initialization explicit.
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import { focusRevealedEditor } from './dialogFocus';
|
||||
import { Calendar, ChevronLeft, ChevronRight, Keyboard } from 'lucide-react';
|
||||
import { localIsoDate } from '../../utils/localDate';
|
||||
import React, { useEffect, useRef, useState } from 'react';
|
||||
@@ -269,7 +270,7 @@ export function CustomDatePicker({
|
||||
<div ref={ref} style={{ position: 'relative', ...style }}>
|
||||
{isTyping ? (
|
||||
<input
|
||||
autoFocus
|
||||
ref={focusRevealedEditor}
|
||||
type="text"
|
||||
value={textInput}
|
||||
onChange={(e) => setTextInput(e.target.value)}
|
||||
|
||||
Reference in New Issue
Block a user