fixed my propries page and fixed the sidebar again mouaz is the best in the west
All checks were successful
Build frontend / build (push) Successful in 45s
All checks were successful
Build frontend / build (push) Successful in 45s
This commit is contained in:
@ -29,10 +29,8 @@ export default function FloatingSidebar({ isRTL, isAdmin }) {
|
|||||||
|
|
||||||
const positionStyle = {
|
const positionStyle = {
|
||||||
left: '16px',
|
left: '16px',
|
||||||
top: 0,
|
top: '50%',
|
||||||
bottom: 0,
|
transform: 'translateY(-50%)',
|
||||||
display: 'flex',
|
|
||||||
alignItems: 'center',
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const cardVariants = {
|
const cardVariants = {
|
||||||
@ -57,7 +55,7 @@ export default function FloatingSidebar({ isRTL, isAdmin }) {
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<motion.div
|
<motion.div
|
||||||
className="fixed z-50 pointer-events-none"
|
className="fixed z-40 pointer-events-none"
|
||||||
style={positionStyle}
|
style={positionStyle}
|
||||||
variants={cardVariants}
|
variants={cardVariants}
|
||||||
initial="initial"
|
initial="initial"
|
||||||
|
|||||||
@ -137,7 +137,7 @@ const PropertyViewModal = ({ isOpen, onClose, property }) => {
|
|||||||
className="bg-white rounded-2xl w-full max-w-4xl max-h-[90vh] overflow-y-auto shadow-2xl"
|
className="bg-white rounded-2xl w-full max-w-4xl max-h-[90vh] overflow-y-auto shadow-2xl"
|
||||||
onClick={(e) => e.stopPropagation()}
|
onClick={(e) => e.stopPropagation()}
|
||||||
>
|
>
|
||||||
<div className="sticky top-0 bg-gradient-to-r from-amber-500 to-amber-600 p-6 text-white flex justify-between items-center">
|
<div className="sticky top-0 z-10 bg-gradient-to-r from-amber-500 to-amber-600 p-6 text-white flex justify-between items-center">
|
||||||
<div>
|
<div>
|
||||||
<h2 className="text-2xl font-bold">{property.title}</h2>
|
<h2 className="text-2xl font-bold">{property.title}</h2>
|
||||||
<p className="text-amber-100 text-sm mt-1">تم الإضافة: {new Date(property.createdAt).toLocaleDateString('ar-SA')}</p>
|
<p className="text-amber-100 text-sm mt-1">تم الإضافة: {new Date(property.createdAt).toLocaleDateString('ar-SA')}</p>
|
||||||
@ -468,12 +468,15 @@ const PropertyEditModal = ({ isOpen, onClose, property, onSave }) => {
|
|||||||
className="bg-white rounded-2xl w-full max-w-4xl max-h-[90vh] overflow-y-auto shadow-2xl"
|
className="bg-white rounded-2xl w-full max-w-4xl max-h-[90vh] overflow-y-auto shadow-2xl"
|
||||||
onClick={(e) => e.stopPropagation()}
|
onClick={(e) => e.stopPropagation()}
|
||||||
>
|
>
|
||||||
<div className="sticky top-0 bg-gradient-to-r from-amber-500 to-amber-600 p-6 text-white flex justify-between items-center">
|
<div className="sticky top-0 z-10 bg-gradient-to-r from-amber-500 to-amber-600 p-6 text-white flex justify-between items-center">
|
||||||
<div>
|
<div>
|
||||||
<h2 className="text-2xl font-bold">تعديل العقار</h2>
|
<h2 className="text-2xl font-bold">تعديل العقار</h2>
|
||||||
<p className="text-amber-100 text-sm mt-1">يمكنك تعديل أي حقل بالضغط على أيقونة القلم</p>
|
<p className="text-amber-100 text-sm mt-1">قم بتحديث معلومات العقار</p>
|
||||||
</div>
|
</div>
|
||||||
<button onClick={onClose} className="p-2 hover:bg-white/20 rounded-full">
|
<button
|
||||||
|
onClick={onClose}
|
||||||
|
className="p-2 hover:bg-white/20 rounded-full transition-colors"
|
||||||
|
>
|
||||||
<XCircle className="w-6 h-6" />
|
<XCircle className="w-6 h-6" />
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
@ -936,7 +939,7 @@ export default function OwnerPropertiesPage() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="min-h-screen bg-gray-50 py-8">
|
<div className="min-h-screen bg-gray-50 py-8 relative">
|
||||||
<Toaster position="top-center" reverseOrder={false} />
|
<Toaster position="top-center" reverseOrder={false} />
|
||||||
|
|
||||||
<DeleteConfirmationModal
|
<DeleteConfirmationModal
|
||||||
@ -1081,7 +1084,7 @@ export default function OwnerPropertiesPage() {
|
|||||||
<img
|
<img
|
||||||
src={property.images[0]}
|
src={property.images[0]}
|
||||||
alt={property.title}
|
alt={property.title}
|
||||||
className="w-full h-full object-cover hover:scale-105 transition-transform duration-300"
|
className="w-full h-full object-cover"
|
||||||
/>
|
/>
|
||||||
) : (
|
) : (
|
||||||
<div className="w-full h-full flex items-center justify-center">
|
<div className="w-full h-full flex items-center justify-center">
|
||||||
@ -1196,8 +1199,9 @@ export default function OwnerPropertiesPage() {
|
|||||||
|
|
||||||
<div className="flex gap-1">
|
<div className="flex gap-1">
|
||||||
<button onClick={() => setViewModal({ isOpen: true, property })}
|
<button onClick={() => setViewModal({ isOpen: true, property })}
|
||||||
className="p-1.5 hover:bg-blue-50 rounded-lg transition-colors group" title="عرض التفاصيل">
|
className="px-3 py-1.5 bg-gray-50 hover:bg-blue-50 border border-gray-200 hover:border-blue-200 rounded-lg transition-all group flex items-center gap-1.5" title="عرض التفاصيل">
|
||||||
<Eye className="w-3.5 h-3.5 text-gray-400 group-hover:text-blue-600" />
|
<Eye className="w-3.5 h-3.5 text-gray-400 group-hover:text-blue-600" />
|
||||||
|
<span className="text-xs text-gray-500 group-hover:text-blue-600 font-medium">عرض</span>
|
||||||
</button>
|
</button>
|
||||||
<button onClick={() => setEditModal({ isOpen: true, property })}
|
<button onClick={() => setEditModal({ isOpen: true, property })}
|
||||||
className="p-1.5 hover:bg-amber-50 rounded-lg transition-colors group" title="تعديل العقار">
|
className="p-1.5 hover:bg-amber-50 rounded-lg transition-colors group" title="تعديل العقار">
|
||||||
|
|||||||
Reference in New Issue
Block a user