Update Documents.tsx
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
import React, { useEffect, useState } from 'react';
|
||||
import { CondoService } from '../services/mockDb';
|
||||
import { Document, Condo } from '../types';
|
||||
import { FileText, Download, Eye, Upload, Tag, Search, Trash2, X, Plus, Filter, Image as ImageIcon, File } from 'lucide-react';
|
||||
import { FileText, Download, Eye, Upload, Tag, Search, Trash2, X, Plus, Filter, Image as ImageIcon, File, Type, AlignLeft } from 'lucide-react';
|
||||
|
||||
export const DocumentsPage: React.FC = () => {
|
||||
const user = CondoService.getCurrentUser();
|
||||
@@ -271,8 +271,14 @@ export const DocumentsPage: React.FC = () => {
|
||||
<button onClick={() => setShowUploadModal(false)}><X className="w-6 h-6 text-slate-400"/></button>
|
||||
</div>
|
||||
<form onSubmit={handleUploadSubmit} className="space-y-4">
|
||||
<input className="w-full border p-2.5 rounded-lg" placeholder="Titolo Documento" value={uploadForm.title} onChange={e => setUploadForm({...uploadForm, title: e.target.value})} required />
|
||||
<textarea className="w-full border p-2.5 rounded-lg h-24" placeholder="Descrizione..." value={uploadForm.description} onChange={e => setUploadForm({...uploadForm, description: e.target.value})} />
|
||||
<div className="relative">
|
||||
<Type className="absolute left-3 top-2.5 w-5 h-5 text-slate-400" />
|
||||
<input className="w-full border p-2.5 pl-10 rounded-lg" placeholder="Titolo Documento" value={uploadForm.title} onChange={e => setUploadForm({...uploadForm, title: e.target.value})} required />
|
||||
</div>
|
||||
<div className="relative">
|
||||
<AlignLeft className="absolute left-3 top-2.5 w-5 h-5 text-slate-400" />
|
||||
<textarea className="w-full border p-2.5 pl-10 rounded-lg h-24" placeholder="Descrizione..." value={uploadForm.description} onChange={e => setUploadForm({...uploadForm, description: e.target.value})} />
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label className="block text-xs font-bold text-slate-500 uppercase mb-1">Tags</label>
|
||||
@@ -283,9 +289,10 @@ export const DocumentsPage: React.FC = () => {
|
||||
</span>
|
||||
))}
|
||||
</div>
|
||||
<div className="flex gap-2">
|
||||
<div className="flex gap-2 relative">
|
||||
<Tag className="absolute left-3 top-2.5 w-4 h-4 text-slate-400" />
|
||||
<input
|
||||
className="flex-1 border p-2 rounded-lg text-sm"
|
||||
className="flex-1 border p-2 pl-9 rounded-lg text-sm"
|
||||
placeholder="Nuovo tag (es. Verbale)"
|
||||
value={uploadForm.currentTagInput}
|
||||
onChange={e => setUploadForm({...uploadForm, currentTagInput: e.target.value})}
|
||||
|
||||
Reference in New Issue
Block a user