i
This commit is contained in:
gr
2026-10-22 11:12:29 +08:00
480 changed files with 9840 additions and 953 deletions
+31 -25
View File
@@ -72,7 +72,7 @@ from .pages import (
ReceptionPage,
)
from .reception_style import TECH_BLUE, body_family, heading_family, number_family
from .theme import COLORS, crisp_pixmap
from .theme import COLORS, TYPE, crisp_pixmap
from .widgets import (
EmptyState,
StatusBadge,
@@ -506,13 +506,14 @@ class _AssistantRobot(QWidget):
painter.setPen(Qt.PenStyle.NoPen)
if self.property("receptionTechBlue"):
painter.setBrush(QColor(TECH_BLUE["accent"]))
painter.drawRoundedRect(QRectF(7, 7, 44, 44), 6, 6)
tile = QRectF(6, 6, 36, 36)
painter.drawRoundedRect(tile, 6, 6)
painter.setPen(QColor(TECH_BLUE["surface"]))
font = QFont(number_family())
font.setPixelSize(21)
font.setPixelSize(18)
font.setWeight(QFont.Weight.DemiBold)
painter.setFont(font)
painter.drawText(QRectF(7, 7, 44, 44), Qt.AlignmentFlag.AlignCenter, "AI")
painter.drawText(tile, Qt.AlignmentFlag.AlignCenter, "AI")
return
painter.setBrush(QColor(COLORS["indigo_pale"]))
painter.drawEllipse(QRectF(1, 1, 54, 54))
@@ -562,14 +563,12 @@ class _AssistantStatus(QLabel):
color = QColor(online_color if self._online else "#EC5266")
painter.setPen(Qt.PenStyle.NoPen)
painter.setBrush(color)
diameter = 9 if reception else 6
diameter = 6
painter.drawEllipse(QRectF(1, (self.height() - diameter) / 2, diameter, diameter))
painter.setPen(color)
font = QFont(self.font())
font.setPixelSize(13 if reception else 10)
painter.setFont(font)
painter.setFont(self.font())
painter.drawText(
QRectF(17 if reception else 12, 0, self.width() - (17 if reception else 12), self.height()),
QRectF(12, 0, self.width() - 12, self.height()),
Qt.AlignmentFlag.AlignLeft | Qt.AlignmentFlag.AlignVCenter,
self.text(),
)
@@ -1085,7 +1084,7 @@ class ShellWindow(QMainWindow):
font-weight: 600;
}
QLabel#ShellAssistantName { color: #1A1C1F; font-size: 13px; font-weight: 500; }
QLabel#ShellAssistantStatus { color: #287B65; font-size: 13px; }
QLabel#ShellAssistantStatus { color: #287B65; font-size: 12px; }
QPushButton#ShellAssistantButton {
min-height: 34px;
color: #FFFFFF;
@@ -1592,15 +1591,16 @@ class ShellWindow(QMainWindow):
self.brand_layout.setSpacing(13 if active else 10)
self.brand_mark.setFixedSize(38 if active else 36, 38 if active else 36)
self.nav_layout.setContentsMargins(*self._navigation_margins())
self.nav_layout.setSpacing(6 if active else 0)
self.assistant_card.setFixedHeight(171 if active else 157)
self.assistant_layout.setContentsMargins(*(13, 19, 13, 20) if active else (12, 12, 12, 20))
self.nav_layout.setSpacing(4 if active else 0)
self.assistant_card.setFixedHeight(132 if active else 157)
self.assistant_layout.setContentsMargins(*(13, 12, 13, 12) if active else (12, 12, 12, 20))
self.assistant_head_layout.setContentsMargins(4 if active else 0, 0, 0, 0)
self.assistant_head_layout.setSpacing(8 if active else 9)
self.assistant_glyph.setFixedSize(48 if active else 56, 48 if active else 56)
self.assistant_outer_layout.setContentsMargins(*(20, 0, 20, 0) if active else (13, 0, 13, 0))
self.assistant_status.setFixedHeight(22 if active else 18)
self.assistant_button.setFixedHeight(46 if active else 34)
self.upload_settings_button.setFixedHeight(94 if active else 44)
self.assistant_status.setFixedHeight(18)
self.assistant_button.setFixedHeight(36 if active else 34)
self.upload_settings_button.setFixedHeight(52 if active else 44)
self.upload_settings_button.setIcon(_painted_shell_icon("settings", 20, reception=True) if active else QIcon())
self.upload_settings_button.setIconSize(QSize(20, 20) if active else QSize(16, 16))
self.upload_settings_button.setText("设置 ›" if active else "设置 ›")
@@ -1686,15 +1686,15 @@ class ShellWindow(QMainWindow):
}}
QLabel#ShellBrandName {{
font-family: "{heading_family()}"; font-weight: 600;
color: {TECH_BLUE['heading']}; font-size: 18px;
color: {TECH_BLUE['heading']}; font-size: {TYPE['fs_section']};
}}
QLabel#ShellBrandSubtitle {{ color: {TECH_BLUE['text']}; font-size: 13px; }}
QLabel#ShellBrandSubtitle {{ color: {TECH_BLUE['muted']}; font-size: {TYPE['fs_small']}; }}
QPushButton#ShellNavButton {{
font-family: "{body_family()}"; font-weight: 400;
min-height: 52px; max-height: 52px;
min-height: 44px; max-height: 44px;
border: 0; border-left: 5px solid transparent;
border-radius: 6px;
padding: 0 16px; font-size: 15px;
padding: 0 16px; font-size: {TYPE['fs_body']};
color: {TECH_BLUE['text']};
}}
QPushButton#ShellNavButton:checked,
@@ -1715,13 +1715,19 @@ class ShellWindow(QMainWindow):
border: 1px solid {_RECEPTION_CHROME_LINE};
}}
QLabel#ShellAssistantName {{
font-family: "{heading_family()}"; font-weight: 500; font-size: 16px;
font-family: "{heading_family()}"; font-weight: 500; font-size: {TYPE['fs_body']};
}}
QLabel#ShellAssistantStatus {{
font-size: {TYPE['fs_small']};
}}
QPushButton#ShellAssistantButton, QPushButton#ShellSettingsButton {{
font-family: "{body_family()}"; font-weight: 400; font-size: 15px;
font-family: "{body_family()}"; font-weight: 400; font-size: {TYPE['fs_body']};
}}
QPushButton#ShellAssistantButton {{ border-radius: 6px; }}
QPushButton#ShellSettingsButton {{ text-align: left; padding: 0 32px; }}
QPushButton#ShellSettingsButton {{
min-height: 50px; max-height: 50px;
text-align: left; padding: 0 32px;
}}
QPushButton#ShellAssistantButton:focus {{
border: 2px solid {TECH_BLUE['focus']};
}}
@@ -1735,12 +1741,12 @@ class ShellWindow(QMainWindow):
QFrame#ShellGlobalSearch {{ border: 1px solid {_RECEPTION_CHROME_LINE}; border-radius: 5px; }}
QFrame#ShellUserSeparator {{ background: {_RECEPTION_CHROME_LINE}; border: 0; }}
QLabel#ShellShortcutHint {{
font-family: "{number_family()}"; font-size: 13px;
font-family: "{number_family()}"; font-size: {TYPE['fs_small']};
padding: 4px 9px; border-radius: 4px;
border: 1px solid {_RECEPTION_CHROME_LINE};
}}
QLineEdit#ShellGlobalSearchInput {{
color: {TECH_BLUE['text']}; font-size: 15px;
color: {TECH_BLUE['text']}; font-size: {TYPE['fs_body']};
min-height: 40px; max-height: 40px;
}}
QPushButton#ShellAiEntry:pressed {{ background: {TECH_BLUE['selection']}; }}