Spaces:
Running
Running
Girish Jeswani commited on
Commit ·
613fa72
1
Parent(s): eb0e90c
fix conflicting css rules
Browse files
phd-advisor-frontend/src/components/MessageBubble.js
CHANGED
|
@@ -270,10 +270,10 @@ const MessageBubble = ({
|
|
| 270 |
|
| 271 |
{showReplyButton && (
|
| 272 |
<div className="message-actions">
|
| 273 |
-
<div className="action-buttons">
|
| 274 |
<div className="tooltip-container">
|
| 275 |
<button
|
| 276 |
-
className="action-button"
|
| 277 |
onClick={() => onReply && onReply(message)}
|
| 278 |
onMouseEnter={() => showTooltipWithDelay('reply')}
|
| 279 |
onMouseLeave={hideTooltip}
|
|
@@ -282,7 +282,7 @@ const MessageBubble = ({
|
|
| 282 |
borderColor: (colors.color ? colors.color + '40' : 'var(--border-muted)')
|
| 283 |
}}
|
| 284 |
>
|
| 285 |
-
<Reply size={14} />
|
| 286 |
</button>
|
| 287 |
{showTooltip === 'reply' && (
|
| 288 |
<div className="tooltip">Reply to this message</div>
|
|
@@ -291,7 +291,7 @@ const MessageBubble = ({
|
|
| 291 |
|
| 292 |
<div className="tooltip-container">
|
| 293 |
<button
|
| 294 |
-
className="action-button"
|
| 295 |
onClick={() => handleCopy(message.id, message?.compact_markdown || message?.content || '')}
|
| 296 |
onMouseEnter={() => showTooltipWithDelay('copy')}
|
| 297 |
onMouseLeave={hideTooltip}
|
|
@@ -311,7 +311,7 @@ const MessageBubble = ({
|
|
| 311 |
|
| 312 |
<div className="tooltip-container">
|
| 313 |
<button
|
| 314 |
-
className="action-button"
|
| 315 |
onClick={() => handleExpand(message.id, personaId)}
|
| 316 |
onMouseEnter={() => showTooltipWithDelay('expand')}
|
| 317 |
onMouseLeave={hideTooltip}
|
|
@@ -329,7 +329,7 @@ const MessageBubble = ({
|
|
| 329 |
|
| 330 |
<div className="tooltip-container">
|
| 331 |
<button
|
| 332 |
-
className="action-button"
|
| 333 |
onClick={handleInfoToggle}
|
| 334 |
onMouseEnter={() => showTooltipWithDelay('info')}
|
| 335 |
onMouseLeave={hideTooltip}
|
|
|
|
| 270 |
|
| 271 |
{showReplyButton && (
|
| 272 |
<div className="message-actions">
|
| 273 |
+
<div className="message-action-buttons">
|
| 274 |
<div className="tooltip-container">
|
| 275 |
<button
|
| 276 |
+
className="message-action-button"
|
| 277 |
onClick={() => onReply && onReply(message)}
|
| 278 |
onMouseEnter={() => showTooltipWithDelay('reply')}
|
| 279 |
onMouseLeave={hideTooltip}
|
|
|
|
| 282 |
borderColor: (colors.color ? colors.color + '40' : 'var(--border-muted)')
|
| 283 |
}}
|
| 284 |
>
|
| 285 |
+
<Reply size={14} stroke="currentColor" fill="none" />
|
| 286 |
</button>
|
| 287 |
{showTooltip === 'reply' && (
|
| 288 |
<div className="tooltip">Reply to this message</div>
|
|
|
|
| 291 |
|
| 292 |
<div className="tooltip-container">
|
| 293 |
<button
|
| 294 |
+
className="message-action-button"
|
| 295 |
onClick={() => handleCopy(message.id, message?.compact_markdown || message?.content || '')}
|
| 296 |
onMouseEnter={() => showTooltipWithDelay('copy')}
|
| 297 |
onMouseLeave={hideTooltip}
|
|
|
|
| 311 |
|
| 312 |
<div className="tooltip-container">
|
| 313 |
<button
|
| 314 |
+
className="message-action-button"
|
| 315 |
onClick={() => handleExpand(message.id, personaId)}
|
| 316 |
onMouseEnter={() => showTooltipWithDelay('expand')}
|
| 317 |
onMouseLeave={hideTooltip}
|
|
|
|
| 329 |
|
| 330 |
<div className="tooltip-container">
|
| 331 |
<button
|
| 332 |
+
className="message-action-button"
|
| 333 |
onClick={handleInfoToggle}
|
| 334 |
onMouseEnter={() => showTooltipWithDelay('info')}
|
| 335 |
onMouseLeave={hideTooltip}
|
phd-advisor-frontend/src/styles/components.css
CHANGED
|
@@ -591,13 +591,13 @@
|
|
| 591 |
border-top: 1px solid var(--border-tertiary);
|
| 592 |
}
|
| 593 |
|
| 594 |
-
.action-buttons {
|
| 595 |
display: flex;
|
| 596 |
align-items: center;
|
| 597 |
gap: 8px;
|
| 598 |
}
|
| 599 |
|
| 600 |
-
.action-button {
|
| 601 |
display: flex;
|
| 602 |
align-items: center;
|
| 603 |
justify-content: center;
|
|
@@ -611,16 +611,22 @@
|
|
| 611 |
position: relative;
|
| 612 |
}
|
| 613 |
|
| 614 |
-
.action-button:hover {
|
| 615 |
background: var(--bg-secondary);
|
| 616 |
transform: translateY(-1px);
|
| 617 |
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
| 618 |
}
|
| 619 |
|
| 620 |
-
.action-button:active {
|
| 621 |
transform: translateY(0);
|
| 622 |
}
|
| 623 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 624 |
/* Tooltip Styles */
|
| 625 |
.tooltip-container {
|
| 626 |
position: relative;
|
|
@@ -686,13 +692,13 @@
|
|
| 686 |
}
|
| 687 |
|
| 688 |
/* Focus states for accessibility */
|
| 689 |
-
.action-button:focus-visible {
|
| 690 |
outline: 2px solid var(--accent-primary);
|
| 691 |
outline-offset: 2px;
|
| 692 |
}
|
| 693 |
|
| 694 |
/* Copy button success state */
|
| 695 |
-
.action-button.copied {
|
| 696 |
color: #10B981 !important;
|
| 697 |
border-color: #10B98140 !important;
|
| 698 |
}
|
|
@@ -1031,11 +1037,11 @@
|
|
| 1031 |
}
|
| 1032 |
|
| 1033 |
/* Smooth transitions */
|
| 1034 |
-
.action-button {
|
| 1035 |
transition: all 0.2s ease;
|
| 1036 |
}
|
| 1037 |
|
| 1038 |
-
.action-button:hover {
|
| 1039 |
transform: translateY(-1px);
|
| 1040 |
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
| 1041 |
}
|
|
@@ -1155,11 +1161,11 @@
|
|
| 1155 |
grid-template-columns: 1fr;
|
| 1156 |
}
|
| 1157 |
|
| 1158 |
-
.action-buttons {
|
| 1159 |
gap: 6px;
|
| 1160 |
}
|
| 1161 |
|
| 1162 |
-
.action-button {
|
| 1163 |
width: 28px;
|
| 1164 |
height: 28px;
|
| 1165 |
}
|
|
|
|
| 591 |
border-top: 1px solid var(--border-tertiary);
|
| 592 |
}
|
| 593 |
|
| 594 |
+
.message-action-buttons {
|
| 595 |
display: flex;
|
| 596 |
align-items: center;
|
| 597 |
gap: 8px;
|
| 598 |
}
|
| 599 |
|
| 600 |
+
.message-action-button {
|
| 601 |
display: flex;
|
| 602 |
align-items: center;
|
| 603 |
justify-content: center;
|
|
|
|
| 611 |
position: relative;
|
| 612 |
}
|
| 613 |
|
| 614 |
+
.message-action-button:hover {
|
| 615 |
background: var(--bg-secondary);
|
| 616 |
transform: translateY(-1px);
|
| 617 |
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
|
| 618 |
}
|
| 619 |
|
| 620 |
+
.message-action-button:active {
|
| 621 |
transform: translateY(0);
|
| 622 |
}
|
| 623 |
|
| 624 |
+
.message-action-button svg {
|
| 625 |
+
width: 14px;
|
| 626 |
+
height: 14px;
|
| 627 |
+
color: inherit;
|
| 628 |
+
}
|
| 629 |
+
|
| 630 |
/* Tooltip Styles */
|
| 631 |
.tooltip-container {
|
| 632 |
position: relative;
|
|
|
|
| 692 |
}
|
| 693 |
|
| 694 |
/* Focus states for accessibility */
|
| 695 |
+
.message-action-button:focus-visible {
|
| 696 |
outline: 2px solid var(--accent-primary);
|
| 697 |
outline-offset: 2px;
|
| 698 |
}
|
| 699 |
|
| 700 |
/* Copy button success state */
|
| 701 |
+
.message-action-button.copied {
|
| 702 |
color: #10B981 !important;
|
| 703 |
border-color: #10B98140 !important;
|
| 704 |
}
|
|
|
|
| 1037 |
}
|
| 1038 |
|
| 1039 |
/* Smooth transitions */
|
| 1040 |
+
.message-action-button {
|
| 1041 |
transition: all 0.2s ease;
|
| 1042 |
}
|
| 1043 |
|
| 1044 |
+
.message-action-button:hover {
|
| 1045 |
transform: translateY(-1px);
|
| 1046 |
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
| 1047 |
}
|
|
|
|
| 1161 |
grid-template-columns: 1fr;
|
| 1162 |
}
|
| 1163 |
|
| 1164 |
+
.message-action-buttons {
|
| 1165 |
gap: 6px;
|
| 1166 |
}
|
| 1167 |
|
| 1168 |
+
.message-action-button {
|
| 1169 |
width: 28px;
|
| 1170 |
height: 28px;
|
| 1171 |
}
|