Sửa callout của hotspot hiển thị thumbnail và tooltip
This commit is contained in:
@@ -597,3 +597,95 @@ html, body {
|
||||
#logout-confirm-modal {
|
||||
z-index: 5500; /* Cao hơn Dashboard (4500) và Close Button (5000) */
|
||||
}
|
||||
|
||||
/* --- Pannellum Custom Hotspot (Callout Bubble) --- */
|
||||
|
||||
/* Container chính của hotspot do Pannellum quản lý */
|
||||
.pnlm-custom-hotspot {
|
||||
width: 64px;
|
||||
height: 64px;
|
||||
/* Căn chỉnh để tâm bong bóng nằm đúng vị trí tọa độ pitch/yaw */
|
||||
margin-left: -32px;
|
||||
margin-top: -32px;
|
||||
z-index: 10;
|
||||
/* Xóa bỏ icon sprite mặc định của Pannellum */
|
||||
background: none !important;
|
||||
}
|
||||
|
||||
.pnlm-custom-hotspot * {
|
||||
box-sizing: border-box;
|
||||
}
|
||||
|
||||
/* Bong bóng callout */
|
||||
.hotspot-callout-bubble {
|
||||
position: relative;
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
cursor: pointer;
|
||||
transition: transform 0.2s ease-in-out;
|
||||
}
|
||||
|
||||
.hotspot-callout-bubble:hover {
|
||||
transform: scale(1.15);
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
/* Khung chứa ảnh thumbnail tròn */
|
||||
.hotspot-thumb-frame {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
border: 3px solid #ffffff;
|
||||
border-radius: 50%;
|
||||
overflow: hidden;
|
||||
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
|
||||
background-color: #333;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
|
||||
.hotspot-thumb-frame img {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
object-fit: cover;
|
||||
}
|
||||
|
||||
/* Đuôi nhọn của bong bóng trỏ xuống vị trí chính xác */
|
||||
.hotspot-callout-bubble::after {
|
||||
content: '';
|
||||
position: absolute;
|
||||
bottom: -10px;
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
border-width: 10px 7px 0;
|
||||
border-style: solid;
|
||||
border-color: #ffffff transparent transparent;
|
||||
}
|
||||
|
||||
/* Tooltip tiêu đề xuất hiện khi hover */
|
||||
.hotspot-callout-title {
|
||||
position: absolute;
|
||||
top: -45px; /* Hiển thị phía trên bong bóng */
|
||||
left: 50%;
|
||||
transform: translateX(-50%);
|
||||
background: rgba(0, 0, 0, 0.85);
|
||||
color: #fff;
|
||||
padding: 5px 12px;
|
||||
border-radius: 20px;
|
||||
font-size: 13px;
|
||||
font-weight: 500;
|
||||
white-space: nowrap;
|
||||
opacity: 0;
|
||||
visibility: hidden;
|
||||
transition: all 0.3s ease;
|
||||
box-shadow: 0 2px 8px rgba(0, 0, 0, 0.5);
|
||||
pointer-events: none;
|
||||
z-index: 100;
|
||||
}
|
||||
|
||||
/* Hiệu ứng khi rê chuột qua hotspot */
|
||||
.hotspot-callout-bubble:hover .hotspot-callout-title {
|
||||
opacity: 1;
|
||||
visibility: visible;
|
||||
top: -55px; /* Nhích lên một chút khi xuất hiện */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user