浏览代码

Allow tabs to have children

master
Adwaith Rao 4 年前
父节点
当前提交
e57ca04323
共有 3 个文件被更改,包括 15999 次插入35 次删除
  1. +15978
    -28
      package-lock.json
  2. +5
    -1
      src/app/tabs/tabs.component.html
  3. +16
    -6
      src/app/tabs/tabs.component.scss

+ 15978
- 28
package-lock.json
文件差异内容过多而无法显示
查看文件


+ 5
- 1
src/app/tabs/tabs.component.html 查看文件

@@ -29,4 +29,8 @@
<button> <button>
<img src="assets/icons/settings.svg" alt="settings icon"> <img src="assets/icons/settings.svg" alt="settings icon">
</button> </button>
</section>
</section>

<div class="page">
<router-outlet></router-outlet>
</div>

+ 16
- 6
src/app/tabs/tabs.component.scss 查看文件

@@ -1,7 +1,9 @@
$header-height: 10rem;

.navbar { .navbar {
display: flex; display: flex;
width: 100%; width: 100%;
height: 10rem;
height: $header-height;
align-items: center; align-items: center;
justify-content: flex-start; justify-content: flex-start;


@@ -83,15 +85,17 @@
} }
} }


$tabs-width: 7rem;
$tabs-offset: 20px;


.tabs { .tabs {
position: fixed; position: fixed;
height: calc(100% - 12rem);
top: 10rem;
left: 4rem;
height: calc(100% - #{$header-height} - 20px);
top: $header-height;
left: $tabs-offset;
background-color: var(--primary); background-color: var(--primary);
border-radius: 5rem;
width: 7rem;
border-radius: $tabs-width;
width: $tabs-width;
overflow: hidden; overflow: hidden;
display: flex; display: flex;
align-items: center; align-items: center;
@@ -118,4 +122,10 @@
} }
} }
} }
}

.page {
height: calc(100vh - #{$header-height});
overflow: auto;
margin-left: calc(#{$tabs-width} + #{$tabs-offset});
} }

正在加载...
取消
保存