mirror of
https://github.com/hcengineering/platform.git
synced 2025-04-15 12:55:59 +00:00
Fix scroll in Panel. Add sizes in Spinner. (#195)
Signed-off-by: Alexander Platov <sas_lord@mail.ru>
This commit is contained in:
parent
e28190ca52
commit
98cc58e138
@ -65,12 +65,10 @@
|
|||||||
<div class="title">{title}</div>
|
<div class="title">{title}</div>
|
||||||
</div>
|
</div>
|
||||||
{#if $$slots.subtitle}<div class="flex-row-center subtitle"><slot name="subtitle" /></div>{/if}
|
{#if $$slots.subtitle}<div class="flex-row-center subtitle"><slot name="subtitle" /></div>{/if}
|
||||||
<div class="flex-col h-full scroll-container">
|
<div class="flex-col scroll-container">
|
||||||
<ScrollBox vertical stretch>
|
<div class="flex-col content">
|
||||||
<div class="flex-col content">
|
<slot />
|
||||||
<slot />
|
</div>
|
||||||
</div>
|
|
||||||
</ScrollBox>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="rightSection">
|
<div class="rightSection">
|
||||||
@ -212,11 +210,11 @@
|
|||||||
.leftSection {
|
.leftSection {
|
||||||
border-right: 1px solid var(--theme-bg-accent-hover);
|
border-right: 1px solid var(--theme-bg-accent-hover);
|
||||||
.scroll-container {
|
.scroll-container {
|
||||||
flex-grow: 1;
|
overflow: auto;
|
||||||
padding: 2rem 2rem 1rem;
|
margin: 2rem 2rem 1.5rem;
|
||||||
.content {
|
.content {
|
||||||
flex-grow: 1;
|
flex-shrink: 0;
|
||||||
padding: .5rem .5rem .5rem;
|
margin: .5rem .5rem 0;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,5 +1,23 @@
|
|||||||
|
<!--
|
||||||
|
// Copyright © 2020 Anticrm Platform Contributors.
|
||||||
|
//
|
||||||
|
// Licensed under the Eclipse Public License, Version 2.0 (the "License");
|
||||||
|
// you may not use this file except in compliance with the License. You may
|
||||||
|
// obtain a copy of the License at https://www.eclipse.org/legal/epl-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing, software
|
||||||
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
//
|
||||||
|
// See the License for the specific language governing permissions and
|
||||||
|
// limitations under the License.
|
||||||
|
-->
|
||||||
|
|
||||||
<div class="spinner">
|
<script lang="ts">
|
||||||
|
export let size: 'small' | 'medium' = 'medium'
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<div class="spinner spinner-{size}">
|
||||||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
|
<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
|
||||||
<path d="M12 0v1c6.1 0 11 4.9 11 11s-4.9 11-11 11v1c6.6 0 12-5.4 12-12S18.6 0 12 0z" fill="#fff"/>
|
<path d="M12 0v1c6.1 0 11 4.9 11 11s-4.9 11-11 11v1c6.6 0 12-5.4 12-12S18.6 0 12 0z" fill="#fff"/>
|
||||||
<linearGradient id="a" gradientUnits="userSpaceOnUse" x1="0" y1="22" x2="0" y2="2">
|
<linearGradient id="a" gradientUnits="userSpaceOnUse" x1="0" y1="22" x2="0" y2="2">
|
||||||
@ -12,10 +30,17 @@
|
|||||||
|
|
||||||
<style lang="scss">
|
<style lang="scss">
|
||||||
.spinner {
|
.spinner {
|
||||||
width: 1.5rem;
|
|
||||||
height: 1.5rem;
|
|
||||||
-webkit-animation: spinCircle 1s infinite linear;
|
-webkit-animation: spinCircle 1s infinite linear;
|
||||||
animation: spinCircle 1s infinite linear;
|
animation: spinCircle 1s infinite linear;
|
||||||
|
|
||||||
|
&-small {
|
||||||
|
width: 1rem;
|
||||||
|
height: 1rem;
|
||||||
|
}
|
||||||
|
&-medium {
|
||||||
|
width: 1.5rem;
|
||||||
|
height: 1.5rem;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
@-webkit-keyframes spinCircle {
|
@-webkit-keyframes spinCircle {
|
||||||
from { -webkit-transform: rotate(0deg); }
|
from { -webkit-transform: rotate(0deg); }
|
||||||
|
@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
<div class="files-container">
|
<div class="files-container">
|
||||||
<span class="icon"><IconFile size={'small'}/></span>
|
<span class="icon"><IconFile size={'small'}/></span>
|
||||||
{Object.values(files).length} file(s)
|
{Object.values(files).length} files
|
||||||
<div class="window">
|
<div class="window">
|
||||||
{#each Object.values(files) as file}
|
{#each Object.values(files) as file}
|
||||||
<div class="flex-row-center file">
|
<div class="flex-row-center file">
|
||||||
@ -41,7 +41,7 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
font-weight: 500;
|
font-weight: 500;
|
||||||
color: var(--theme-caption-color);
|
color: var(--theme-content-color);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
.icon {
|
.icon {
|
||||||
@ -51,6 +51,7 @@
|
|||||||
opacity: .6;
|
opacity: .6;
|
||||||
}
|
}
|
||||||
&:hover {
|
&:hover {
|
||||||
|
color: var(--theme-caption-color);
|
||||||
.icon { opacity: 1; }
|
.icon { opacity: 1; }
|
||||||
.window { visibility: visible; }
|
.window { visibility: visible; }
|
||||||
&::after { content: ''; }
|
&::after { content: ''; }
|
||||||
|
Loading…
Reference in New Issue
Block a user