 {
        const now = new Date();
        const diff = now - timestamp;

        // Convert to seconds
        const seconds = Math.floor(diff / 1000);

        if (seconds < 5) {
          return "just now";
        }
        if (seconds < 60) {
          return `${seconds} seconds ago`;
        }

        // Convert to minutes
        const minutes = Math.floor(seconds / 60);
        if (minutes === 1) {
          return "1 minute ago";
        }
        if (minutes < 60) {
          return `${minutes} m