-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
57 changed files
with
3,334 additions
and
3,850 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -41,3 +41,5 @@ testem.log | |
.DS_Store | ||
Thumbs.db | ||
.nx/ | ||
|
||
.vscode/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1 @@ | ||
v20.14.0 | ||
20 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Large diffs are not rendered by default.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
130 changes: 51 additions & 79 deletions
130
projects/demo-showcase/src/app/page-features-viewer/page-features-viewer.component.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,82 +1,54 @@ | ||
<div class="container pt-3"> | ||
<!-- Section: introduction --> | ||
<div class="mb-3"> | ||
<h1>Feature viewer</h1> | ||
<p> | ||
The feature viewer allows you to represent features on a reference seqeunce... | ||
</p> | ||
</div> | ||
<!-- Section: example --> | ||
<div class="d-flex flex-row gap-3 mb-3"> | ||
<!-- TODO Remove this --> | ||
<div style="display: block; width: 1rem; height: 1rem; background: black; font-size: 1rem; line-height: 1rem;"> | ||
<!-- Section: introduction --> | ||
<div class="mb-3"> | ||
<h1>Feature viewer</h1> | ||
<p> | ||
The feature viewer allows you to represent features on a reference seqeunce... | ||
</p> | ||
</div> | ||
|
||
<div style="display: block; height: auto; overflow: hidden; width: 100%;"> | ||
<ngx-features-viewer [sequence]="sequence" [traces]="traces" [settings]="(settings$ | async)!" | ||
(selectedFeature)="onFeatureSelected($event)"> | ||
<!-- Left label --> | ||
<ng-template let-trace="trace" ngx-features-viewer-label> | ||
<div class="d-flex h-100 w-100 justify-content-start pe-0 align-items-center font-monospace"> | ||
<div [class.text-muted]="trace.nested?.length > 0 && !trace.expanded"> | ||
{{ ' '.repeat(trace.level) }}{{ trace.label }} | ||
@if (trace.nested?.length > 0) { | ||
<!-- Add symbol if expanded --> | ||
@if (trace.expanded) { | ||
<i class="bi bi-caret-down-fill"></i> | ||
} @else { | ||
<i class="bi bi-caret-right"></i> | ||
} | ||
} | ||
</div> | ||
</div> | ||
<div | ||
style="display: block; width: 1rem; height: auto; background: black; color: white; font-size: 1rem; line-height: .5rem;"> | ||
W</div> | ||
<div | ||
style="display: block; width: auto; height: 1rem; background: black; color: white; font-size: 1rem; line-height: 1rem;"> | ||
W</div> | ||
</div> | ||
<!-- TODO Remove this --> | ||
<div class="d-block mb-3"> | ||
<p> | ||
Lorem ipsum dolor sit amet, consectetur adipiscing elit. Cras congue velit in sem sodales pretium. Vivamus | ||
sit amet enim malesuada, efficitur quam quis, semper metus. Aenean commodo tellus eu viverra lacinia. Nam | ||
sed lectus non tellus suscipit pellentesque. Class aptent taciti sociosqu ad litora torquent per conubia | ||
nostra, per inceptos himenaeos. Suspendisse lacus diam, laoreet eget nisl et, dictum dictum elit. Vivamus | ||
sit amet fringilla elit, vitae pulvinar nisl. Donec mattis magna lacus, id congue risus aliquet a. | ||
</p> | ||
<p> | ||
Cras nec malesuada risus. Integer a tincidunt ante. Vivamus eu mauris placerat, dictum diam vitae, laoreet | ||
eros. Integer porttitor neque vel lectus ullamcorper commodo. Aliquam erat volutpat. Morbi convallis | ||
fermentum mauris, quis aliquet tellus posuere non. Nunc aliquet mattis tellus et ultrices. | ||
</p> | ||
</div> | ||
<!-- Show output --> | ||
<div style="display: block; height: auto; width: 100%;"> | ||
<ngx-features-viewer [sequence]="sequence" [features]="features" [settings]="settings"> | ||
<!-- Left label --> | ||
<ng-template let-trace="trace" ngx-features-viewer-label> | ||
<div [class.text-muted]="!trace.expanded"> | ||
{{ trace.label }} | ||
<!-- Add symbol if expanded --> | ||
@if (trace.expanded) { | ||
<i class="bi bi-caret-down-fill"></i> | ||
} @else { | ||
<i class="bi bi-caret-right"></i> | ||
} | ||
</div> | ||
</ng-template> | ||
<!-- Right label --> | ||
<ng-template let-trace="trace" ngx-features-viewer-label="right"> | ||
<div [class.text-muted]="!trace.expanded"> | ||
Right label! | ||
</div> | ||
</ng-template> | ||
</ngx-features-viewer> | ||
</div> | ||
<!-- TODO Remove this --> | ||
<div> | ||
<p> | ||
Morbi convallis ipsum sit amet felis faucibus mollis. Duis nec viverra nisl, nec maximus nisl. Proin non | ||
malesuada massa, sit amet auctor elit. Sed condimentum, urna id commodo semper, nisi lorem lobortis velit, | ||
eu | ||
auctor ante magna eu nibh. Aliquam mattis pulvinar sapien vitae rhoncus. Sed lacinia ex a ultrices finibus. | ||
Phasellus eu erat eu sapien laoreet dapibus ac vitae mauris. | ||
</p> | ||
<p> | ||
Vestibulum elementum sem vel lorem suscipit varius. Mauris malesuada porta sapien blandit facilisis. Aliquam | ||
pretium erat nec lorem molestie, et feugiat turpis semper. Donec tempus posuere nibh, maximus hendrerit odio | ||
eleifend vitae. Praesent consequat felis leo, at ullamcorper nisl dictum sed. Morbi erat dui, sollicitudin | ||
id | ||
interdum convallis, elementum laoreet lorem. Duis leo massa, commodo id tempor sed, semper ut dui. Proin | ||
faucibus feugiat sapien, et cursus nunc. Duis eu mattis ipsum, ac facilisis quam. Donec a sapien non lectus | ||
iaculis luctus. Nulla lobortis turpis id nisi consectetur aliquet. Aliquam dignissim aliquam erat, at | ||
egestas | ||
nulla ullamcorper a. Duis porta interdum venenatis. Praesent a lorem at velit egestas efficitur eu et | ||
lectus. | ||
Suspendisse potenti. Duis imperdiet aliquam hendrerit. | ||
</p> | ||
</div> | ||
</ng-template> | ||
<!-- Right label --> | ||
<ng-template let-trace="trace" ngx-features-viewer-label where="right"> | ||
<div class="d-flex h-100 w-100 justify-content-center align-items-center font-monospace"> | ||
<button class="btn btn-sm btn-primary" (click)="onTraceButtonClick(trace)">Trace {{ trace.id }}</button> | ||
</div> | ||
</ng-template> | ||
<!-- Tooltip template --> | ||
<ng-template let-trace="trace" let-feature="feature" let-index="index" let-coordinates="coordinates" | ||
ngx-features-viewer-tooltip> | ||
<div class="tooltipOuter"> | ||
{{ feature.label }} | ||
</div> | ||
|
||
<!-- <ngx-features-viewer [sequence]="sequence" [settings]="settings.inner" [traces]="[trace]">--> | ||
<!-- <!– Define simple label left –>--> | ||
<!-- <ng-template let-trace="trace" ngx-features-viewer-label>--> | ||
<!-- <div class="d-flex h-100 w-100 justify-content-start pe-0 align-items-center font-monospace">--> | ||
<!-- {{ trace.label }}--> | ||
<!-- </div>--> | ||
<!-- </ng-template>--> | ||
<!-- </ngx-features-viewer>--> | ||
</ng-template> | ||
</ngx-features-viewer> | ||
</div> | ||
<!-- </div>--> | ||
</div> |
19 changes: 19 additions & 0 deletions
19
projects/demo-showcase/src/app/page-features-viewer/page-features-viewer.component.scss
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,20 @@ | ||
ngx-features-viewer { | ||
--feature-cursor: pointer; | ||
--overlay-cursor: col-resize; | ||
--feature-hover-outline: 2px outset #00ffa0; | ||
--locus-hover-border-radius: 4px; | ||
} | ||
|
||
.tooltipOuter { | ||
border-style: solid; | ||
border-width: 1px; | ||
border-radius: 4px; | ||
border-color: rgb(255, 255, 255); | ||
white-space: nowrap; | ||
|
||
box-shadow: rgba(0, 0, 0, 0.2) 1px 2px 10px; | ||
background-color: rgb(255, 255, 255); | ||
color: rgb(102, 102, 102); | ||
font: 14px / 21px sans-serif; | ||
padding: 10px; | ||
} |
Oops, something went wrong.