iloom-flatten/.microcompact/mpmjrpl6/functions.Edit:18.txt

18 lines
688 B
Plaintext

The file /home/project/src/components/warehouse/ProductForm.tsx has been updated. Made 1 replacement.
Here's the result of running `cat -n` on a snippet of the edited file:
286→ const triggerFileSelect = () => {
287→ fileInputRef.current?.click();
288→ };
289→
290→ const addYarnRatio = () => {
291→ setFormData(prev => ({
292→ ...prev,
293→ yarn_ratios: [...prev.yarn_ratios, { yarn_name: '', ratio: 100, yarn_type: 'all' }]
294→ }));
295→ };
296→
297→ const removeYarnRatio = (index: number) => {
298→ setFormData(prev => ({
299→ ...prev,
300→ yarn_ratios: prev.yarn_ratios.filter((_, i) => i !== index)