-
Notifications
You must be signed in to change notification settings - Fork 33
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #687 from geonetwork/DH/vue-api-datahub
[Datahub] Add an API form generator for OGC API Records
- Loading branch information
Showing
38 changed files
with
874 additions
and
71 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
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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
.tab-header-label { | ||
@apply uppercase text-sm text-primary opacity-75 hover:text-primary-darker; | ||
} |
89 changes: 65 additions & 24 deletions
89
apps/datahub/src/app/record/record-apis/record-apis.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,25 +1,66 @@ | ||
<p | ||
class="font-title text-[28px] font-medium mt-8 mb-5 text-title text-center sm:mt-12 sm:mb-[-22px] sm:text-left" | ||
translate | ||
> | ||
record.metadata.api | ||
</p> | ||
<gn-ui-carousel | ||
containerClass="gap-4 py-10" | ||
stepsContainerClass="right-[var(--container-outside-width)] bottom-[calc(100%-12px)] top-auto" | ||
> | ||
<gn-ui-api-card | ||
*ngFor=" | ||
let link of facade.apiLinks$ | async; | ||
let first = first; | ||
let last = last | ||
" | ||
[link]="link" | ||
class="w-80" | ||
[ngClass]="{ | ||
'mr-[var(--container-outside-width)]': last, | ||
'ml-[var(--container-outside-width)]': first | ||
}" | ||
<div class="container-lg px-4 lg:mx-auto"> | ||
<p | ||
class="font-title text-[28px] font-medium mt-8 mb-5 text-title text-center sm:mt-12 sm:mb-[-22px] sm:text-left" | ||
translate | ||
> | ||
</gn-ui-api-card> | ||
</gn-ui-carousel> | ||
record.metadata.api | ||
</p> | ||
<gn-ui-carousel | ||
containerClass="gap-4 py-10" | ||
stepsContainerClass="right-[var(--container-outside-width)] bottom-[calc(100%-12px)] top-auto" | ||
> | ||
<gn-ui-api-card | ||
*ngFor=" | ||
let link of facade.apiLinks$ | async; | ||
let first = first; | ||
let last = last | ||
" | ||
[link]="link" | ||
[currentLink]="selectedApiLink" | ||
class="w-80" | ||
[ngClass]="{ | ||
'mr-[var(--container-outside-width)]': last, | ||
'ml-[var(--container-outside-width)]': first, | ||
'card-shadow': link !== selectedApiLink || !selectedApiLink, | ||
'bg-neutral-100': link === selectedApiLink | ||
}" | ||
(openRecordApiForm)="openRecordApiForm($event)" | ||
> | ||
</gn-ui-api-card> | ||
</gn-ui-carousel> | ||
</div> | ||
<div | ||
class="content overflow-hidden transition-all duration-300" | ||
[ngClass]="selectedApiLink ? 'ease-in' : 'ease-out'" | ||
[style.maxHeight]="maxHeight" | ||
[style.opacity]="opacity" | ||
> | ||
<div class="bg-primary-opacity-10 py-8"> | ||
<div class="flex flex-col px-4 gap-8 container-lg lg:mx-auto"> | ||
<div class="flex flex-wrap justify-between sm:mb-2 ng-star-inserted"> | ||
<p class="text-[21px] text-title font-title" translate> | ||
record.metadata.api.form.title | ||
</p> | ||
<button | ||
type="button" | ||
class="flex items-center gap-0.5 text-primary group" | ||
(click)="closeRecordApiForm()" | ||
> | ||
<div | ||
class="text-sm font-medium opacity-50 group-hover:opacity-100 uppercase tracking-wide mt-0.5" | ||
translate | ||
> | ||
record.metadata.api.form.closeButton | ||
</div> | ||
<mat-icon | ||
class="!w-5 !h-5 text-xl font-bold material-symbols-outlined !flex items-center" | ||
>close</mat-icon | ||
> | ||
</button> | ||
</div> | ||
<gn-ui-record-api-form | ||
[apiLink]="selectedApiLink" | ||
></gn-ui-record-api-form> | ||
</div> | ||
</div> | ||
</div> |
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
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
Oops, something went wrong.