| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148 |
- @use '../../../../../shared/styles/_ios-theme.scss' as *;
- // 横向滑动条式选项卡导航
- .horizontal-tab-nav {
- position: relative;
- display: flex;
- flex-direction: column;
- width: 100%;
- background: $ios-background;
- border-radius: $ios-radius-lg;
- overflow: hidden;
- box-shadow: $ios-shadow-sm;
- }
- .tab-container {
- display: flex;
- position: relative;
- background: rgba(0, 122, 255, 0.05);
- border-radius: $ios-radius-lg;
- padding: 4px;
- }
- .tab-item {
- flex: 1;
- display: flex;
- align-items: center;
- justify-content: center;
- padding: 12px 16px;
- border: none;
- background: transparent;
- color: $ios-text-secondary;
- font-size: $ios-font-size-md;
- font-weight: $ios-font-weight-medium;
- cursor: pointer;
- transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- border-radius: $ios-radius-md;
- position: relative;
- z-index: 2;
- min-width: 120px;
- &:hover {
- color: $ios-primary;
- background: rgba(0, 122, 255, 0.08);
- }
- &.active {
- color: $ios-primary;
- font-weight: $ios-font-weight-semibold;
- }
- .tab-text {
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- transition: all 0.3s ease;
- }
- }
- // 滑动指示器
- .tab-indicator {
- position: absolute;
- top: 4px;
- left: 4px;
- height: calc(100% - 8px);
- width: 120px;
- background: $ios-background;
- border-radius: $ios-radius-md;
- box-shadow: 0 2px 8px rgba(0, 122, 255, 0.15);
- transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
- z-index: 1;
- }
- // 响应式设计
- @media (max-width: 768px) {
- .horizontal-tab-nav {
- margin: 0 -8px;
- }
-
- .tab-item {
- padding: 10px 12px;
- font-size: $ios-font-size-sm;
- min-width: 100px;
- }
-
- .tab-indicator {
- width: 100px;
- }
- }
- @media (max-width: 480px) {
- .tab-item {
- padding: 8px 10px;
- font-size: 13px;
- min-width: 80px;
- }
-
- .tab-indicator {
- width: 80px;
- }
- }
- // 保持向后兼容的垂直导航样式(如果需要)
- .vertical-nav {
- display: flex;
- flex-direction: column;
- gap: $ios-spacing-xs;
- padding: $ios-spacing-sm;
- background: $ios-background;
- border-radius: $ios-radius-md;
- border: 1px solid $ios-border;
- box-shadow: $ios-shadow-sm;
- min-width: 160px;
- max-width: 200px;
- width: 100%;
- .nav-item {
- display: flex;
- align-items: center;
- padding: $ios-spacing-xs $ios-spacing-sm;
- border-radius: $ios-radius-sm;
- cursor: pointer;
- transition: all 0.2s ease;
- color: $ios-text-primary;
- text-decoration: none;
- font-size: $ios-font-size-sm;
- font-weight: $ios-font-weight-regular;
- line-height: 1.2;
- background: transparent;
- border: none;
- &:hover {
- background-color: $ios-background-secondary;
- }
- &.active {
- background-color: $ios-primary;
- color: white;
- font-weight: $ios-font-weight-medium;
- }
- .nav-text {
- white-space: nowrap;
- overflow: hidden;
- text-overflow: ellipsis;
- flex: 1;
- }
- }
- }
|