mirror of
https://github.com/R0m1k3/Socialflow.git
synced 2026-10-24 07:28:11 +02:00
3 files changed
+26
-7
No files matched your search
@@ -46,10 +46,6 @@ externalPort = 6000
|
|||||||
localPort = 43245
|
localPort = 43245
|
||||||
externalPort = 3001
|
externalPort = 3001
|
||||||
|
|
||||||
[[ports]]
|
|
||||||
localPort = 44509
|
|
||||||
externalPort = 8000
|
|
||||||
|
|
||||||
[[ports]]
|
[[ports]]
|
||||||
localPort = 46681
|
localPort = 46681
|
||||||
externalPort = 5173
|
externalPort = 5173
|
||||||
|
|||||||
@@ -131,11 +131,15 @@ export default function MediaUpload() {
|
|||||||
className="flex items-center gap-4 p-4 rounded-xl bg-muted/30 border border-border/50 cursor-pointer hover:bg-muted hover:shadow-md transition-all"
|
className="flex items-center gap-4 p-4 rounded-xl bg-muted/30 border border-border/50 cursor-pointer hover:bg-muted hover:shadow-md transition-all"
|
||||||
data-testid={`media-item-${media.id}`}
|
data-testid={`media-item-${media.id}`}
|
||||||
>
|
>
|
||||||
<div className="w-14 h-14 rounded-lg bg-gradient-to-br from-muted to-muted/50 flex items-center justify-center flex-shrink-0">
|
<div className="w-14 h-14 rounded-lg bg-gradient-to-br from-muted to-muted/50 flex items-center justify-center flex-shrink-0 overflow-hidden">
|
||||||
{media.type === "video" ? (
|
{media.type === "video" ? (
|
||||||
<Video className="w-7 h-7 text-secondary" />
|
<Video className="w-7 h-7 text-secondary" />
|
||||||
) : (
|
) : (
|
||||||
<ImageIcon className="w-7 h-7 text-primary" />
|
<img
|
||||||
|
src={media.originalUrl}
|
||||||
|
alt={media.fileName}
|
||||||
|
className="w-full h-full object-cover"
|
||||||
|
/>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
<div className="flex-1 min-w-0">
|
<div className="flex-1 min-w-0">
|
||||||
|
|||||||
@@ -1,7 +1,7 @@
|
|||||||
import { useState, useCallback, useRef } from "react";
|
import { useState, useCallback, useRef } from "react";
|
||||||
import { useQuery, useMutation } from "@tanstack/react-query";
|
import { useQuery, useMutation } from "@tanstack/react-query";
|
||||||
import { useLocation } from "wouter";
|
import { useLocation } from "wouter";
|
||||||
import { Send, Sparkles, Image as ImageIcon, Calendar, Upload, Camera, GripVertical } from "lucide-react";
|
import { Send, Sparkles, Image as ImageIcon, Calendar, Upload, Camera, GripVertical, Loader2 } from "lucide-react";
|
||||||
import { useDropzone } from "react-dropzone";
|
import { useDropzone } from "react-dropzone";
|
||||||
import {
|
import {
|
||||||
DndContext,
|
DndContext,
|
||||||
@@ -29,6 +29,7 @@ import { Input } from "@/components/ui/input";
|
|||||||
import { Label } from "@/components/ui/label";
|
import { Label } from "@/components/ui/label";
|
||||||
import { Checkbox } from "@/components/ui/checkbox";
|
import { Checkbox } from "@/components/ui/checkbox";
|
||||||
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select";
|
import { Select, SelectContent, SelectItem, SelectTrigger, SelectValue } from "@/components/ui/select";
|
||||||
|
import { Dialog, DialogContent } from "@/components/ui/dialog";
|
||||||
import { useToast } from "@/hooks/use-toast";
|
import { useToast } from "@/hooks/use-toast";
|
||||||
import { apiRequest, queryClient } from "@/lib/queryClient";
|
import { apiRequest, queryClient } from "@/lib/queryClient";
|
||||||
import type { SocialPage, Media } from "@shared/schema";
|
import type { SocialPage, Media } from "@shared/schema";
|
||||||
@@ -691,6 +692,24 @@ export default function NewPost() {
|
|||||||
</div>
|
</div>
|
||||||
</main>
|
</main>
|
||||||
|
|
||||||
|
<Dialog open={uploadMutation.isPending}>
|
||||||
|
<DialogContent className="sm:max-w-md [&>button]:hidden">
|
||||||
|
<div className="flex flex-col items-center justify-center py-8">
|
||||||
|
<div className="w-20 h-20 rounded-full bg-primary/10 flex items-center justify-center mb-6">
|
||||||
|
<Loader2 className="w-10 h-10 text-primary animate-spin" />
|
||||||
|
</div>
|
||||||
|
<h3 className="text-xl font-semibold text-foreground mb-2">
|
||||||
|
Upload en cours...
|
||||||
|
</h3>
|
||||||
|
<p className="text-sm text-muted-foreground text-center">
|
||||||
|
Votre image est en cours de téléchargement et de traitement.
|
||||||
|
<br />
|
||||||
|
Veuillez patienter.
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
|
</DialogContent>
|
||||||
|
</Dialog>
|
||||||
|
|
||||||
<PreviewModal
|
<PreviewModal
|
||||||
open={previewModalOpen}
|
open={previewModalOpen}
|
||||||
onOpenChange={setPreviewModalOpen}
|
onOpenChange={setPreviewModalOpen}
|
||||||
|
|||||||
Reference in new issue
Block a user