Update: GTM Architect v2.6.2 (Edit Specs, Report Fix) & Company Explorer v0.4 (Export, Timestamps)
This commit is contained in:
@@ -78,7 +78,7 @@ export const Layout: React.FC<LayoutProps> = ({
|
||||
<div>
|
||||
<h1 className="text-xl font-bold font-mono tracking-tighter flex items-center gap-2 text-slate-900 dark:text-white">
|
||||
<div className="w-3 h-3 bg-robo-500 dark:bg-robo-accent rounded-full animate-pulse"></div>
|
||||
ROBOPLANET v2.5
|
||||
ROBOPLANET v2.6
|
||||
</h1>
|
||||
<p className="text-xs mt-1 uppercase tracking-widest text-slate-500 dark:text-robo-400">GTM Architect Engine</p>
|
||||
</div>
|
||||
|
||||
@@ -1,37 +1,277 @@
|
||||
/* ... (existing styles) ... */
|
||||
.session-browser {
|
||||
padding: 1rem;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
}
|
||||
|
||||
.product-description {
|
||||
font-size: 0.9rem;
|
||||
color: #555;
|
||||
margin-bottom: 12px;
|
||||
height: 4.5em; /* Approximately 3 lines of text */
|
||||
.browser-header {
|
||||
display: flex;
|
||||
justify_content: space-between;
|
||||
align-items: center;
|
||||
margin-bottom: 1.5rem;
|
||||
padding-bottom: 1rem;
|
||||
border-bottom: 1px solid #e2e8f0;
|
||||
}
|
||||
|
||||
.browser-header h2 {
|
||||
font-size: 1.5rem;
|
||||
font-weight: 700;
|
||||
color: #1e293b;
|
||||
}
|
||||
|
||||
.dark .browser-header h2 {
|
||||
color: #f1f5f9;
|
||||
}
|
||||
|
||||
.start-new-btn {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.5rem;
|
||||
background-color: #2563eb;
|
||||
color: white;
|
||||
padding: 0.5rem 1rem;
|
||||
border-radius: 0.5rem;
|
||||
font-weight: 600;
|
||||
transition: background-color 0.2s;
|
||||
}
|
||||
|
||||
.start-new-btn:hover {
|
||||
background-color: #1d4ed8;
|
||||
}
|
||||
|
||||
/* LIST LAYOUT */
|
||||
.session-grid {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
max-width: 1200px;
|
||||
margin: 0 auto;
|
||||
}
|
||||
|
||||
.session-card {
|
||||
background: white;
|
||||
border: 1px solid #e2e8f0;
|
||||
border-radius: 0.75rem;
|
||||
padding: 1.25rem;
|
||||
display: flex;
|
||||
align-items: flex-start; /* Align top for multi-line description */
|
||||
gap: 1.5rem;
|
||||
transition: all 0.2s ease;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.dark .session-card {
|
||||
background: #1e293b;
|
||||
border-color: #334155;
|
||||
}
|
||||
|
||||
.session-card:hover {
|
||||
transform: translateY(-1px);
|
||||
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
|
||||
border-color: #94a3b8;
|
||||
}
|
||||
|
||||
/* Header Section (Left) */
|
||||
.card-header {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 1rem;
|
||||
width: 280px; /* Fixed width for alignment */
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.category-badge {
|
||||
font-size: 1.75rem;
|
||||
background: #f1f5f9;
|
||||
width: 3.5rem;
|
||||
height: 3.5rem;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
border-radius: 0.75rem;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.dark .category-badge {
|
||||
background: #334155;
|
||||
}
|
||||
|
||||
.card-title-container {
|
||||
flex: 1;
|
||||
min-width: 0;
|
||||
}
|
||||
|
||||
.card-title {
|
||||
font-weight: 700;
|
||||
font-size: 1rem;
|
||||
color: #0f172a;
|
||||
white-space: nowrap;
|
||||
overflow: hidden;
|
||||
text-overflow: ellipsis;
|
||||
margin-bottom: 0.25rem;
|
||||
}
|
||||
|
||||
.dark .card-title {
|
||||
color: #f8fafc;
|
||||
}
|
||||
|
||||
.card-date {
|
||||
font-size: 0.75rem;
|
||||
color: #64748b;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 0.25rem;
|
||||
}
|
||||
|
||||
/* Content Section (Middle) */
|
||||
.card-content {
|
||||
flex: 1;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
padding-right: 1rem;
|
||||
border-right: 1px solid #f1f5f9;
|
||||
}
|
||||
|
||||
.dark .card-content {
|
||||
border-right-color: #334155;
|
||||
}
|
||||
|
||||
.product-description {
|
||||
font-size: 0.875rem;
|
||||
color: #475569;
|
||||
line-height: 1.5;
|
||||
display: -webkit-box;
|
||||
-webkit-line-clamp: 3;
|
||||
-webkit-line-clamp: 2;
|
||||
-webkit-box-orient: vertical;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.source-url {
|
||||
font-size: 0.8rem;
|
||||
margin-bottom: 12px;
|
||||
.dark .product-description {
|
||||
color: #94a3b8;
|
||||
}
|
||||
|
||||
.source-url a {
|
||||
color: #007bff;
|
||||
.card-meta {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
gap: 1rem;
|
||||
font-size: 0.75rem;
|
||||
}
|
||||
|
||||
.source-link {
|
||||
display: inline-flex;
|
||||
align-items: center;
|
||||
gap: 0.25rem;
|
||||
color: #3b82f6;
|
||||
text-decoration: none;
|
||||
transition: color 0.2s;
|
||||
font-weight: 500;
|
||||
padding: 0.25rem 0.5rem;
|
||||
background: #eff6ff;
|
||||
border-radius: 0.25rem;
|
||||
transition: background 0.2s;
|
||||
}
|
||||
|
||||
.source-url a:hover {
|
||||
color: #0056b3;
|
||||
text-decoration: underline;
|
||||
.dark .source-link {
|
||||
background: #1e3a8a;
|
||||
color: #bfdbfe;
|
||||
}
|
||||
|
||||
.last-updated {
|
||||
font-size: 0.8rem;
|
||||
color: #888;
|
||||
margin-top: auto; /* Pushes to the bottom if content is short */
|
||||
.source-link:hover {
|
||||
background: #dbeafe;
|
||||
}
|
||||
|
||||
/* ... (rest of the styles) ... */
|
||||
/* Actions Section (Right) */
|
||||
.card-actions {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
gap: 0.5rem;
|
||||
width: 120px;
|
||||
flex-shrink: 0;
|
||||
}
|
||||
|
||||
.load-btn {
|
||||
width: 100%;
|
||||
background-color: #0f172a;
|
||||
color: white;
|
||||
padding: 0.5rem;
|
||||
border-radius: 0.5rem;
|
||||
font-weight: 600;
|
||||
font-size: 0.875rem;
|
||||
text-align: center;
|
||||
transition: opacity 0.2s;
|
||||
}
|
||||
|
||||
.dark .load-btn {
|
||||
background-color: #f8fafc;
|
||||
color: #0f172a;
|
||||
}
|
||||
|
||||
.load-btn:hover {
|
||||
opacity: 0.9;
|
||||
}
|
||||
|
||||
.delete-btn {
|
||||
width: 100%;
|
||||
padding: 0.5rem;
|
||||
border-radius: 0.5rem;
|
||||
color: #ef4444;
|
||||
background-color: transparent;
|
||||
border: 1px solid #fecaca;
|
||||
font-size: 0.875rem;
|
||||
text-align: center;
|
||||
transition: all 0.2s;
|
||||
}
|
||||
|
||||
.dark .delete-btn {
|
||||
border-color: #7f1d1d;
|
||||
color: #fca5a5;
|
||||
}
|
||||
|
||||
.delete-btn:hover {
|
||||
background-color: #fef2f2;
|
||||
}
|
||||
|
||||
.dark .delete-btn:hover {
|
||||
background-color: #450a0a;
|
||||
}
|
||||
|
||||
/* Responsive adjustments */
|
||||
@media (max-width: 768px) {
|
||||
.session-card {
|
||||
flex-direction: column;
|
||||
gap: 1rem;
|
||||
}
|
||||
|
||||
.card-header, .card-content, .card-actions {
|
||||
width: 100%;
|
||||
border-right: none;
|
||||
padding-right: 0;
|
||||
}
|
||||
|
||||
.card-actions {
|
||||
flex-direction: row;
|
||||
}
|
||||
}
|
||||
|
||||
.empty-state {
|
||||
text-align: center;
|
||||
padding: 4rem;
|
||||
color: #64748b;
|
||||
}
|
||||
|
||||
.start-new-btn-secondary {
|
||||
margin-top: 1rem;
|
||||
padding: 0.75rem 1.5rem;
|
||||
background: white;
|
||||
border: 1px solid #cbd5e1;
|
||||
border-radius: 0.5rem;
|
||||
font-weight: 600;
|
||||
color: #475569;
|
||||
transition: all 0.2s;
|
||||
}
|
||||
|
||||
.start-new-btn-secondary:hover {
|
||||
border-color: #94a3b8;
|
||||
background: #f8fafc;
|
||||
}
|
||||
@@ -15,18 +15,18 @@ const SessionBrowser: React.FC<SessionBrowserProps> = ({ sessions, onLoadSession
|
||||
const getCategoryIcon = (category: string) => {
|
||||
// Return an icon based on the category, default to a generic robot
|
||||
if (!category) return '🤖';
|
||||
switch (category.toLowerCase()) {
|
||||
case 'reinigungsroboter':
|
||||
return '🧹';
|
||||
case 'serviceroboter':
|
||||
return '🛎️';
|
||||
case 'transportroboter':
|
||||
return '📦';
|
||||
case 'security roboter':
|
||||
return '🛡️';
|
||||
default:
|
||||
return '🤖';
|
||||
}
|
||||
const cat = category.toLowerCase();
|
||||
|
||||
if (cat.includes('reinigung') || cat.includes('cleaning')) return '🧹';
|
||||
if (cat.includes('service') || cat.includes('kellner')) return '🛎️';
|
||||
if (cat.includes('transport') || cat.includes('logistik') || cat.includes('logistics')) return '📦';
|
||||
if (cat.includes('security') || cat.includes('sicherheit') || cat.includes('wach')) return '🛡️';
|
||||
if (cat.includes('inspektion') || cat.includes('inspection')) return '🔍';
|
||||
if (cat.includes('humanoid')) return '🦾';
|
||||
if (cat.includes('drohne') || cat.includes('drone')) return '🚁';
|
||||
if (cat.includes('rasen') || cat.includes('mower')) return '🌱';
|
||||
|
||||
return '🤖';
|
||||
};
|
||||
|
||||
return (
|
||||
@@ -48,27 +48,48 @@ const SessionBrowser: React.FC<SessionBrowserProps> = ({ sessions, onLoadSession
|
||||
) : (
|
||||
<div className="session-grid">
|
||||
{sessions.map((session) => (
|
||||
<div key={session.id} className="session-card">
|
||||
<div key={session.id} className="session-card group">
|
||||
{/* Left Column: Icon & Title */}
|
||||
<div className="card-header">
|
||||
<span className="category-icon">{getCategoryIcon(session.productCategory)}</span>
|
||||
<h3 title={session.productName}>{session.productName || 'Unbenannt'}</h3>
|
||||
</div>
|
||||
<div className="thumbnail-placeholder">
|
||||
<span>🖼️</span>
|
||||
<p>Thumbnail</p>
|
||||
<div className="category-badge" title={session.productCategory}>
|
||||
{getCategoryIcon(session.productCategory)}
|
||||
</div>
|
||||
<div className="card-title-container">
|
||||
<h3 className="card-title" title={session.productName}>{session.productName || 'Unbenanntes Projekt'}</h3>
|
||||
<div className="card-date">
|
||||
<span className="text-xs text-slate-400">Updated:</span>
|
||||
{new Date(session.updated_at).toLocaleDateString()}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Middle Column: Description & Meta */}
|
||||
<div className="card-content">
|
||||
<p className="product-description">{session.productDescription || 'Keine Beschreibung verfügbar.'}</p>
|
||||
<p className="source-url">
|
||||
<a href={session.sourceUrl} target="_blank" rel="noopener noreferrer">
|
||||
Quelle anzeigen
|
||||
</a>
|
||||
<p className="product-description">
|
||||
{session.productDescription && session.productDescription !== "No description available."
|
||||
? session.productDescription
|
||||
: <span className="italic text-slate-400">Keine Beschreibung verfügbar.</span>}
|
||||
</p>
|
||||
<p className="last-updated">Zuletzt bearbeitet: {new Date(session.updated_at).toLocaleString()}</p>
|
||||
|
||||
<div className="card-meta">
|
||||
{session.sourceUrl && session.sourceUrl !== "No source URL found." && (
|
||||
<a href={session.sourceUrl} target="_blank" rel="noopener noreferrer" className="source-link">
|
||||
🔗 Link zur Quelle
|
||||
</a>
|
||||
)}
|
||||
<span className="text-slate-400">•</span>
|
||||
<span className="text-slate-500">{session.productCategory || 'Unkategorisiert'}</span>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{/* Right Column: Actions */}
|
||||
<div className="card-actions">
|
||||
<button onClick={() => onLoadSession(session.id)} className="load-btn">Laden</button>
|
||||
<button onClick={() => onDeleteSession(session.id)} className="delete-btn">Löschen</button>
|
||||
<button onClick={() => onLoadSession(session.id)} className="load-btn">
|
||||
Öffnen
|
||||
</button>
|
||||
<button onClick={() => onDeleteSession(session.id)} className="delete-btn" title="Löschen">
|
||||
Löschen
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
))}
|
||||
|
||||
Reference in New Issue
Block a user