Skip to content

Commit b1073cb

Browse files
committed
Add fuzzy search hints to directors, writers, and cast input fields
- Update placeholder text with example names (e.g. James Cameron) - Add helper text indicating fuzzy matching support for typo tolerance
1 parent 010b146 commit b1073cb

1 file changed

Lines changed: 12 additions & 3 deletions

File tree

mflix/client/app/components/SearchMovieModal/SearchMovieModal.tsx

Lines changed: 12 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -256,9 +256,12 @@ export default function SearchMovieModal({
256256
onChange={(e) => handleInputChange('directors', e.target.value)}
257257
className={`${styles.input} ${errors.directors ? styles.inputError : ''}`}
258258
disabled={isLoading}
259-
placeholder="Director names"
259+
placeholder="e.g. James Cameron"
260260
/>
261261
{errors.directors && <span className={styles.error}>{errors.directors}</span>}
262+
<small className={styles.searchOperatorDescription}>
263+
Fuzzy matching enabled – tolerates minor typos
264+
</small>
262265
</div>
263266

264267
{/* Writers Search */}
@@ -273,9 +276,12 @@ export default function SearchMovieModal({
273276
onChange={(e) => handleInputChange('writers', e.target.value)}
274277
className={`${styles.input} ${errors.writers ? styles.inputError : ''}`}
275278
disabled={isLoading}
276-
placeholder="Writer names"
279+
placeholder="e.g. Aaron Sorkin"
277280
/>
278281
{errors.writers && <span className={styles.error}>{errors.writers}</span>}
282+
<small className={styles.searchOperatorDescription}>
283+
Fuzzy matching enabled – tolerates minor typos
284+
</small>
279285
</div>
280286

281287
{/* Cast Search */}
@@ -290,9 +296,12 @@ export default function SearchMovieModal({
290296
onChange={(e) => handleInputChange('cast', e.target.value)}
291297
className={`${styles.input} ${errors.cast ? styles.inputError : ''}`}
292298
disabled={isLoading}
293-
placeholder="Actor names"
299+
placeholder="e.g. Tom Hanks"
294300
/>
295301
{errors.cast && <span className={styles.error}>{errors.cast}</span>}
302+
<small className={styles.searchOperatorDescription}>
303+
Fuzzy matching enabled – tolerates minor typos
304+
</small>
296305
</div>
297306

298307
{/* Limit */}

0 commit comments

Comments
 (0)