diff --git a/utils/section-scroll/section-scroll.component.css b/utils/section-scroll/section-scroll.component.css index 79c74613..2dd17209 100644 --- a/utils/section-scroll/section-scroll.component.css +++ b/utils/section-scroll/section-scroll.component.css @@ -1,10 +1,44 @@ -/* hide scrollbar but allow scrolling */ -*[scroll] { - -ms-overflow-style: none; /* for Internet Explorer, Edge */ - scrollbar-width: none; /* for Firefox */ - overflow-y: scroll; +.section { + position: relative; + height: auto; + /*display: flex;*/ } -*[scroll]::-webkit-scrollbar { - display: none; /* for Chrome, Safari, and Opera */ +.section [top] { + /*height: 80vh;*/ + /*border: 1px solid rebeccapurple;*/ +} + +.section [top] { + position: sticky; + top: 0; + z-index: 2; + height: auto; + /*max-height: 80vh;*/ + /*border: 1px solid deeppink;*/ +} + +/*.content {*/ +/* position: relative;*/ +/* height: auto;*/ +/* z-index: 1;*/ +/* border: 1px solid cyan;*/ +/*}*/ + +[left] { + position: sticky; + top: 0; + height: 100vh; + /*border: 1px solid red;*/ +} + +[left] img { + /*position: absolute;*/ + /*top: 50%;*/ + /*left: 50%;*/ + /*transform: translate(-50%, -50%);*/ + position: sticky; + top: 50%; + left: 10%; + /*border: 1px solid greenyellow;*/ } diff --git a/utils/section-scroll/section-scroll.component.ts b/utils/section-scroll/section-scroll.component.ts index 92c57971..fb8ae08d 100644 --- a/utils/section-scroll/section-scroll.component.ts +++ b/utils/section-scroll/section-scroll.component.ts @@ -11,10 +11,21 @@ import {Component, HostListener, Input, OnInit, ViewEncapsulation} from "@angula @Component({ selector: 'section-scroll', template: ` -