diff --git a/src/app/features/auth/pages/sign-up/sign-up.component.html b/src/app/features/auth/pages/sign-up/sign-up.component.html index 8f44b82aa..e24464c60 100644 --- a/src/app/features/auth/pages/sign-up/sign-up.component.html +++ b/src/app/features/auth/pages/sign-up/sign-up.component.html @@ -4,11 +4,17 @@

{{ 'auth.signUp.title' | translate }}

- + Orchid icon - - + +
diff --git a/src/app/features/collections/components/collections-main-content/collections-main-content.component.ts b/src/app/features/collections/components/collections-main-content/collections-main-content.component.ts index b4524bce7..2d8a090ac 100644 --- a/src/app/features/collections/components/collections-main-content/collections-main-content.component.ts +++ b/src/app/features/collections/components/collections-main-content/collections-main-content.component.ts @@ -19,7 +19,6 @@ import { CollectionsSearchResultsComponent } from '../collections-search-results @Component({ selector: 'osf-collections-main-content', - standalone: true, imports: [ NgOptimizedImage, Select, diff --git a/src/app/features/moderation/components/collection-moderators-list/collection-moderators-list.component.html b/src/app/features/moderation/components/collection-moderators-list/collection-moderators-list.component.html index 02cb0065f..591d85b4f 100644 --- a/src/app/features/moderation/components/collection-moderators-list/collection-moderators-list.component.html +++ b/src/app/features/moderation/components/collection-moderators-list/collection-moderators-list.component.html @@ -78,7 +78,7 @@ - + diff --git a/src/app/features/project/contributors/components/contributors-list/contributors-list.component.html b/src/app/features/project/contributors/components/contributors-list/contributors-list.component.html index 60fedef2d..1453eaa9e 100644 --- a/src/app/features/project/contributors/components/contributors-list/contributors-list.component.html +++ b/src/app/features/project/contributors/components/contributors-list/contributors-list.component.html @@ -19,7 +19,7 @@
{{ 'project.contributors.table.headers.permissions' | translate }} - +

{{ 'project.contributors.permissionInfo.title' | translate }}

@@ -57,7 +57,7 @@

{{ 'project.contributors.permissionInfo.title' | translate }}

{{ 'project.contributors.table.headers.contributor' | translate }} - +

{{ 'project.contributors.bibliographicContributorInfo.heading' | translate }}

@@ -73,7 +73,7 @@

{{ 'project.contributors.bibliographicContributorInfo.heading' | translate }
{{ 'project.contributors.table.headers.curator' | translate }} - +

{{ 'project.contributors.curatorInfo.heading' | translate }}

@@ -148,7 +148,13 @@

{{ 'project.contributors.curatorInfo.heading' | translate }}

- + diff --git a/src/app/features/project/contributors/components/create-view-link-dialog/create-view-link-dialog.component.html b/src/app/features/project/contributors/components/create-view-link-dialog/create-view-link-dialog.component.html index dca09e02d..135c3e6b5 100644 --- a/src/app/features/project/contributors/components/create-view-link-dialog/create-view-link-dialog.component.html +++ b/src/app/features/project/contributors/components/create-view-link-dialog/create-view-link-dialog.component.html @@ -55,7 +55,7 @@ class="w-full" styleClass="w-full" (click)="dialogRef.close()" - [text]="true" + text severity="info" [label]="'project.contributors.addDialog.cancel' | translate" > diff --git a/src/app/features/project/contributors/contributors.component.html b/src/app/features/project/contributors/contributors.component.html index 130383454..581e756be 100644 --- a/src/app/features/project/contributors/contributors.component.html +++ b/src/app/features/project/contributors/contributors.component.html @@ -75,7 +75,7 @@

{{ 'navigation.project.contributors' | tra class="w-3" styleClass="w-full" (click)="cancel()" - [text]="true" + text severity="info" [label]="'common.buttons.cancel' | translate" > diff --git a/src/app/features/project/files/components/file-detail/components/file-metadata/file-metadata.component.ts b/src/app/features/project/files/components/file-detail/components/file-metadata/file-metadata.component.ts index d733d1cbe..98870b892 100644 --- a/src/app/features/project/files/components/file-detail/components/file-metadata/file-metadata.component.ts +++ b/src/app/features/project/files/components/file-detail/components/file-metadata/file-metadata.component.ts @@ -18,7 +18,6 @@ import { LANGUAGES, RESOURCE_TYPES } from '../../constants/files-details.constan @Component({ selector: 'osf-file-metadata', - standalone: true, imports: [Button, Dialog, InputText, Select, FormsModule, ReactiveFormsModule, Skeleton, TranslateModule], templateUrl: './file-metadata.component.html', styleUrl: './file-metadata.component.scss', diff --git a/src/app/features/project/files/components/file-detail/components/project-metadata/project-metadata.component.ts b/src/app/features/project/files/components/file-detail/components/project-metadata/project-metadata.component.ts index f7832a276..a9dbe65b1 100644 --- a/src/app/features/project/files/components/file-detail/components/project-metadata/project-metadata.component.ts +++ b/src/app/features/project/files/components/file-detail/components/project-metadata/project-metadata.component.ts @@ -9,7 +9,6 @@ import { ProjectFilesSelectors } from '@osf/features/project/files/store'; @Component({ selector: 'osf-project-metadata', - standalone: true, imports: [DatePipe, TranslateModule], templateUrl: './project-metadata.component.html', styleUrl: './project-metadata.component.scss', diff --git a/src/app/features/project/files/components/move-file-dialog/move-file-dialog.component.html b/src/app/features/project/files/components/move-file-dialog/move-file-dialog.component.html index 010b5a3b3..dd0674e0d 100644 --- a/src/app/features/project/files/components/move-file-dialog/move-file-dialog.component.html +++ b/src/app/features/project/files/components/move-file-dialog/move-file-dialog.component.html @@ -57,12 +57,7 @@

{{ 'project.files.emptyState' | transl }
- + @if (this.config.data.action === 'move') {
diff --git a/src/app/features/project/overview/components/linked-projects/linked-projects.component.html b/src/app/features/project/overview/components/linked-projects/linked-projects.component.html index 732d95773..89b51d278 100644 --- a/src/app/features/project/overview/components/linked-projects/linked-projects.component.html +++ b/src/app/features/project/overview/components/linked-projects/linked-projects.component.html @@ -16,8 +16,13 @@

{{ linkedProject.title }}

- - + diff --git a/src/app/features/project/settings/mappers/view-only-links.mapper.ts b/src/app/features/project/settings/mappers/view-only-links.mapper.ts index e2270ccb5..2726cd954 100644 --- a/src/app/features/project/settings/mappers/view-only-links.mapper.ts +++ b/src/app/features/project/settings/mappers/view-only-links.mapper.ts @@ -10,8 +10,8 @@ export class ViewOnlyLinksMapper { name: item.attributes.name, anonymous: item.attributes.anonymous, creator: { - fullName: item.relationships.creator.data?.id ?? '', - url: item.relationships.creator.links.related.href, + id: item.embeds.creator.data.id, + fullName: item.embeds.creator.data.attributes.full_name ?? '', }, nodes: [], })); @@ -36,8 +36,8 @@ export class ViewOnlyLinksMapper { name: item.attributes.name, anonymous: item.attributes.anonymous, creator: { - fullName: item.relationships.creator.data?.id ?? '', - url: item.relationships.creator.links.related.href, + id: item.embeds.creator.data.id, + fullName: item.embeds.creator.data.attributes.full_name ?? '', }, nodes: [], }; diff --git a/src/app/features/project/settings/models/view-only-link-response.model.ts b/src/app/features/project/settings/models/view-only-link-response.model.ts index 6b96537a5..5692975e1 100644 --- a/src/app/features/project/settings/models/view-only-link-response.model.ts +++ b/src/app/features/project/settings/models/view-only-link-response.model.ts @@ -1,3 +1,5 @@ +import { UserGetResponse } from '@osf/core/models'; + export interface ViewOnlyLinksResponseModel { data: ViewOnlyLink[]; links: PaginationLinks; @@ -15,6 +17,11 @@ export interface ViewOnlyLink { anonymous: boolean; name: string; }; + embeds: { + creator: { + data: UserGetResponse; + }; + }; relationships: { creator: { links: { diff --git a/src/app/features/project/settings/models/view-only-link.model.ts b/src/app/features/project/settings/models/view-only-link.model.ts index e377fe11d..fa84b83c5 100644 --- a/src/app/features/project/settings/models/view-only-link.model.ts +++ b/src/app/features/project/settings/models/view-only-link.model.ts @@ -1,6 +1,6 @@ export interface ViewOnlyLinkCreatorModel { + id: string; fullName: string; - url: string; } export interface ViewOnlyLinkNodeModel { diff --git a/src/app/features/project/settings/pipes/notification-description.pipe.ts b/src/app/features/project/settings/pipes/notification-description.pipe.ts index cef2d524b..8322ae5a3 100644 --- a/src/app/features/project/settings/pipes/notification-description.pipe.ts +++ b/src/app/features/project/settings/pipes/notification-description.pipe.ts @@ -6,7 +6,6 @@ import { SubscriptionEvent, SubscriptionFrequency } from '@shared/enums'; @Pipe({ name: 'notificationDescription', - standalone: true, }) export class NotificationDescriptionPipe implements PipeTransform { constructor(private translate: TranslateService) {} diff --git a/src/app/features/project/settings/services/view-only-links.service.ts b/src/app/features/project/settings/services/view-only-links.service.ts index b9a740b4e..bbc0f510e 100644 --- a/src/app/features/project/settings/services/view-only-links.service.ts +++ b/src/app/features/project/settings/services/view-only-links.service.ts @@ -16,16 +16,19 @@ export class ViewOnlyLinksService { private readonly jsonApiService = inject(JsonApiService); getViewOnlyLinksData(projectId: string): Observable { + const params: Record = { embed: 'creator' }; + return this.jsonApiService - .get(`${environment.apiUrl}/nodes/${projectId}/view_only_links`) + .get(`${environment.apiUrl}/nodes/${projectId}/view_only_links`, params) .pipe(map((response) => ViewOnlyLinksMapper.fromResponse(response, projectId))); } createViewOnlyLink(projectId: string, payload: ViewOnlyLink): Observable { + const data = { data: { ...payload } }; + const params: Record = { embed: 'creator' }; + return this.jsonApiService - .post(`${environment.apiUrl}/nodes/${projectId}/view_only_links/`, { - data: { ...payload }, - }) + .post(`${environment.apiUrl}/nodes/${projectId}/view_only_links/`, data, params) .pipe(map((response) => ViewOnlyLinksMapper.fromSingleResponse(response, projectId))); } diff --git a/src/app/features/project/settings/settings.component.html b/src/app/features/project/settings/settings.component.html index 6bda0ffe7..6209cad4a 100644 --- a/src/app/features/project/settings/settings.component.html +++ b/src/app/features/project/settings/settings.component.html @@ -78,8 +78,7 @@

{{ 'myProjects.settings.projectAffiliation' | translate

{{ affiliation }}

- - +
}

diff --git a/src/app/features/project/settings/store/settings.state.ts b/src/app/features/project/settings/store/settings.state.ts index 5d4741d93..bd4c56569 100644 --- a/src/app/features/project/settings/store/settings.state.ts +++ b/src/app/features/project/settings/store/settings.state.ts @@ -212,6 +212,11 @@ export class SettingsState { @Action(CreateViewOnlyLink) createViewOnlyLink(ctx: StateContext, action: CreateViewOnlyLink) { const state = ctx.getState(); + + ctx.patchState({ + viewOnlyLinks: { ...state.viewOnlyLinks, isLoading: true, error: null }, + }); + return this.viewOnlyLinksService.createViewOnlyLink(action.projectId, action.payload).pipe( tap((data: PaginatedViewOnlyLinksModel) => { ctx.patchState({ @@ -231,6 +236,12 @@ export class SettingsState { @Action(DeleteViewOnlyLink) deleteViewOnlyLink(ctx: StateContext, action: DeleteViewOnlyLink) { + const state = ctx.getState(); + + ctx.patchState({ + viewOnlyLinks: { ...state.viewOnlyLinks, isLoading: true, error: null }, + }); + return this.viewOnlyLinksService.deleteLink(action.projectId, action.linkId).pipe( tap(() => { ctx.setState( diff --git a/src/app/features/project/wiki/components/wiki-list/wiki-list.component.html b/src/app/features/project/wiki/components/wiki-list/wiki-list.component.html index f61388b66..d3e9340ac 100644 --- a/src/app/features/project/wiki/components/wiki-list/wiki-list.component.html +++ b/src/app/features/project/wiki/components/wiki-list/wiki-list.component.html @@ -19,7 +19,14 @@ outlined (click)="openAddWikiDialog()" /> - +
@if (!isHomeWikiSelected() || !list().length) { @@ -67,7 +74,14 @@

{{ item.label }}

- + } }
diff --git a/src/app/features/settings/account-settings/components/deactivate-account/components/cancel-deactivation/cancel-deactivation.component.html b/src/app/features/settings/account-settings/components/deactivate-account/components/cancel-deactivation/cancel-deactivation.component.html index 239af46f3..8a8bcea7b 100644 --- a/src/app/features/settings/account-settings/components/deactivate-account/components/cancel-deactivation/cancel-deactivation.component.html +++ b/src/app/features/settings/account-settings/components/deactivate-account/components/cancel-deactivation/cancel-deactivation.component.html @@ -13,7 +13,7 @@