Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
40 commits
Select commit Hold shift + click to select a range
147aeda
Fix/improvements (#319)
nsemets Sep 4, 2025
c3b84df
Test/387 settings page tokens (#318)
dinlvkdn Sep 4, 2025
4b26233
Fix - Search (#286)
rrromchIk Sep 4, 2025
9d8e653
Fix/557 missing tooltip (#320)
nsemets Sep 4, 2025
182ab37
chore(test-env): added test env (#321)
nsemets Sep 4, 2025
f47fc34
Chore/test docs added more docs and updated docs in the ever expandin…
bp-cos Sep 4, 2025
7058fd7
Fix/registrations (#326)
nsemets Sep 5, 2025
301e653
fix(redirect-link): removed it (#327)
nsemets Sep 5, 2025
1729d0e
[ENG-8505] Finished adding the GFP to the files page (#325)
bp-cos Sep 5, 2025
7eaa041
Test/565 my projects (#334)
dinlvkdn Sep 8, 2025
4f62983
Feat/550 file widget (#323)
nmykhalkevch-exoft Sep 8, 2025
8343301
Fix/metadata (#336)
nsemets Sep 8, 2025
8abf420
chore(env): updated env files (#328)
nsemets Sep 8, 2025
57bcf64
fix(redirect): fixed redirect after registration (#339)
nmykhalkevch-exoft Sep 9, 2025
e7f000d
Test/576 analytics (#341)
dinlvkdn Sep 9, 2025
e7e52e7
Feat - Admin institution filters (#333)
rrromchIk Sep 9, 2025
a7c6adf
Fix - Preprints bugs (#337)
rrromchIk Sep 9, 2025
4c38cd8
Fix/affiliated institutions (#342)
nsemets Sep 9, 2025
0c983a6
Fix/affiliated institutions (#344)
nsemets Sep 9, 2025
71ad49f
Feat/185 - Linked services (#338)
rnastyuk Sep 10, 2025
318d371
Fix/clean code (#347)
nsemets Sep 10, 2025
395102a
fix(file): downloads link (#346)
nmykhalkevch-exoft Sep 10, 2025
760e324
Test/580 home page (#348)
dinlvkdn Sep 10, 2025
a89e735
Fix/overview (#349)
nsemets Sep 10, 2025
e0fc915
fix(children): refactor get children request (#351)
nmykhalkevch-exoft Sep 10, 2025
ff673ac
Fix/overview (#352)
nsemets Sep 10, 2025
ac6e1ed
fix(bugs): fixed bugs (#354)
nsemets Sep 10, 2025
ede02f8
Feat(project-redirect-modal): added project redirect modal (#350)
rnastyuk Sep 10, 2025
d07e4f3
Test/395 institutions components (#358)
dinlvkdn Sep 11, 2025
978ce90
Fix/registration bugs (#356)
nmykhalkevch-exoft Sep 11, 2025
2dedc73
fix(tags-input): Fix strange behaviour when removing first tag (#361)
rrromchIk Sep 11, 2025
38570f5
Fix/accessibility (#359)
nsemets Sep 11, 2025
e8c4d67
Fix/search filters (#360)
rrromchIk Sep 11, 2025
391944b
Feat(ENG-8625): add Recent Activity to registrations (#315)
sh-andriy Sep 11, 2025
103dae5
fix(recent-activity): updated some code (#364)
nsemets Sep 11, 2025
2c07219
Merge remote-tracking branch 'origin/develop' into fix/dev-to-main
nsemets Sep 11, 2025
dfd8c4d
fix(errors): fixed some issues
nsemets Sep 11, 2025
9e087e8
fix(dashboard): fixed bugs
nsemets Sep 11, 2025
c6c0e10
fix(tests): fixed unit tests
nsemets Sep 11, 2025
f168d3c
fix(config): added error handling
nsemets Sep 11, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
49 changes: 7 additions & 42 deletions jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -62,56 +62,21 @@ module.exports = {
testPathIgnorePatterns: [
'<rootDir>/src/app/app.config.ts',
'<rootDir>/src/app/app.routes.ts',
'<rootDir>/src/app/features/project/addons/components/configure-configure-addon/',
'<rootDir>/src/app/features/project/addons/components/connect-configured-addon/',
'<rootDir>/src/app/features/project/addons/components/disconnect-addon-modal/',
'<rootDir>/src/app/features/project/addons/components/confirm-account-connection-modal/',
'<rootDir>/src/app/features/files/components/create-folder-dialog',
'<rootDir>/src/app/features/files/components/edit-file-metadata-dialog',
'<rootDir>/src/app/features/files/components/file-keywords',
'<rootDir>/src/app/features/files/components/file-metadata',
'<rootDir>/src/app/features/files/components/file-resource-metadata',
'<rootDir>/src/app/features/files/components/move-file-dialog',
'<rootDir>/src/app/features/files/components/rename-file-dialog',
'<rootDir>/src/app/features/files/pages/community-metadata',
'<rootDir>/src/app/features/my-projects/',
'<rootDir>/src/app/features/project/analytics/',
'<rootDir>/src/app/features/project/contributors/',
'<rootDir>/src/app/features/project/files/',
'<rootDir>/src/app/features/project/metadata/',
'<rootDir>/src/app/features/project/registrations',
'<rootDir>/src/app/features/project/settings',
'<rootDir>/src/app/features/project/wiki',
'<rootDir>/src/app/features/project/project.component.ts',
'<rootDir>/src/app/features/registries/pages',
'<rootDir>/src/app/features/registries/registries.component.spec.ts',
'<rootDir>/src/app/features/registries/components/metadata/contributors',
'<rootDir>/src/app/features/registries/components/metadata/registries-license',
'<rootDir>/src/app/features/registries/components/metadata/registries-subjects',
'<rootDir>/src/app/features/registries/components/confirm-continue-editing-dialog',
'<rootDir>/src/app/features/registries/components/confirm-registration-dialog',
'<rootDir>/src/app/features/registries/components/custom-step',
'<rootDir>/src/app/features/registries/components/drafts',
'<rootDir>/src/app/features/registries/components/files-control',
'<rootDir>/src/app/features/registries/components/justification-review',
'<rootDir>/src/app/features/registries/components/justification-step',
'<rootDir>/src/app/features/registries/components/new-registration',
'<rootDir>/src/app/features/registries/components/registry-provider-hero',
'<rootDir>/src/app/features/registries/components/registry-services',
'<rootDir>/src/app/features/registries/components/review',
'<rootDir>/src/app/features/registries/components/select-components-dialog',
'<rootDir>/src/app/features/files/components',
'<rootDir>/src/app/features/files/pages/file-detail',
'<rootDir>/src/app/features/preprints/',
'<rootDir>/src/app/features/project/',
'<rootDir>/src/app/features/registries/',
'<rootDir>/src/app/features/registry/',
'<rootDir>/src/app/features/settings/addons/',
'<rootDir>/src/app/features/settings/tokens/mappers/',
'<rootDir>/src/app/features/settings/tokens/store/',
'<rootDir>/src/app/shared/components/file-menu/',
'<rootDir>/src/app/shared/components/files-tree/',
'<rootDir>/src/app/shared/components/line-chart/',
'<rootDir>/src/app/shared/components/make-decision-dialog/',
'<rootDir>/src/app/shared/components/pie-chart/',
'<rootDir>/src/app/shared/components/resource-citations/',
'<rootDir>/src/app/shared/components/reusable-filter/',
'<rootDir>/src/app/shared/components/shared-metadata/dialogs/affiliated-institutions-dialog/',
'<rootDir>/src/app/shared/components/shared-metadata/dialogs/contributors-dialog/',
'<rootDir>/src/app/shared/components/shared-metadata/shared-metadata',
'<rootDir>/src/app/shared/components/wiki/edit-section/',
'<rootDir>/src/app/shared/components/wiki/wiki-list/',
],
Expand Down
4 changes: 3 additions & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,6 @@
"@angular/platform-browser": "^19.2.0",
"@angular/platform-browser-dynamic": "^19.2.0",
"@angular/router": "^19.2.0",
"@angular/service-worker": "^19.2.0",
"@fortawesome/fontawesome-free": "^6.7.2",
"@ngx-translate/core": "^16.0.4",
"@ngx-translate/http-loader": "^16.0.1",
Expand Down
8 changes: 6 additions & 2 deletions src/app/app.component.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import { OSFConfigService } from '@core/services/osf-config.service';
import { GetCurrentUser, UserState } from '@core/store/user';
import { UserEmailsState } from '@core/store/user-emails';

import { FullScreenLoaderComponent, ToastComponent } from './shared/components';
import { CookieConsentComponent, FullScreenLoaderComponent, ToastComponent } from './shared/components';
import { TranslateServiceMock } from './shared/mocks';
import { AppComponent } from './app.component';

Expand All @@ -33,7 +33,11 @@ describe('Component: App', () => {
} as any;

await TestBed.configureTestingModule({
imports: [OSFTestingModule, AppComponent, ...MockComponents(ToastComponent, FullScreenLoaderComponent)],
imports: [
OSFTestingModule,
AppComponent,
...MockComponents(ToastComponent, FullScreenLoaderComponent, CookieConsentComponent),
],
providers: [
provideStore([UserState, UserEmailsState]),
TranslateServiceMock,
Expand Down
5 changes: 0 additions & 5 deletions src/app/app.routes.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,11 +35,6 @@ export const routes: Routes = [
canActivate: [authGuard],
providers: [provideStates([ProjectsState])],
},
{
path: 'confirm/:userId/:token',
loadComponent: () => import('./features/home/home.component').then((mod) => mod.HomeComponent),
data: { skipBreadcrumbs: true },
},
{
path: 'register',
canActivate: [redirectIfLoggedInGuard],
Expand Down
8 changes: 4 additions & 4 deletions src/app/core/components/breadcrumb/breadcrumb.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ export class BreadcrumbComponent {
private readonly router = inject(Router);
private readonly route = inject(ActivatedRoute);

protected readonly url = toSignal(
readonly url = toSignal(
this.router.events.pipe(
filter((event) => event instanceof NavigationEnd),
map(() => this.router.url),
Expand All @@ -26,7 +26,7 @@ export class BreadcrumbComponent {
{ initialValue: this.router.url }
);

protected readonly routeData = toSignal(
readonly routeData = toSignal(
this.router.events.pipe(
filter((event) => event instanceof NavigationEnd),
map(() => this.getCurrentRouteData()),
Expand All @@ -35,9 +35,9 @@ export class BreadcrumbComponent {
{ initialValue: { skipBreadcrumbs: false } as RouteData }
);

protected readonly showBreadcrumb = computed(() => this.routeData()?.skipBreadcrumbs !== true);
readonly showBreadcrumb = computed(() => this.routeData()?.skipBreadcrumbs !== true);

protected readonly parsedUrl = computed(() =>
readonly parsedUrl = computed(() =>
this.url()
.split('?')[0]
.split('/')
Expand Down
8 changes: 4 additions & 4 deletions src/app/core/components/footer/footer.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
</div>
</div>

<div class="footer-socials flex justify-content-center align-items-center" [class]="isWeb() ? 'm-y-12' : 'm-y-24'">
<div class="footer-socials flex justify-content-center align-items-center" [class]="isWeb() ? 'my-3' : 'my-4'">
@for (icon of socialIcons; track icon.name) {
<a
class="social-link flex align-items-center justify-content-center"
Expand All @@ -21,9 +21,9 @@

<div
class="footer-secondary-nav flex flex-column justify-content-center align-items-center md:flex-row md:justify-content-between"
[class.m-t-24]="!isWeb()"
[class.mt-4]="!isWeb()"
>
<div class="footer-links flex flex-wrap justify-content-center m-t-4">
<div class="footer-links flex flex-wrap justify-content-center mt-1">
<a routerLink="/terms-of-use">{{ 'footer.links.termsOfUse' | translate }}</a>

<span class="separator">|</span>
Expand All @@ -43,6 +43,6 @@
<a href="https://www.cos.io/initiatives/top-guidelines">{{ 'footer.links.topGuidelines' | translate }}</a>
</div>

<div class="flex justify-content-center m-y-12">{{ 'footer.copyright' | translate }}</div>
<div class="flex justify-content-center my-3">{{ 'footer.copyright' | translate }}</div>
</div>
</footer>
2 changes: 1 addition & 1 deletion src/app/core/components/footer/footer.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,5 +18,5 @@ import { IS_WEB } from '@osf/shared/helpers';
export class FooterComponent {
isWeb = toSignal(inject(IS_WEB));

protected readonly socialIcons = SOCIAL_ICONS;
readonly socialIcons = SOCIAL_ICONS;
}
16 changes: 8 additions & 8 deletions src/app/core/components/nav-menu/nav-menu.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export class NavMenuComponent {
private readonly isAuthenticated = select(UserSelectors.isAuthenticated);
private readonly currentResource = select(CurrentResourceSelectors.getCurrentResource);

protected readonly mainMenuItems = computed(() => {
readonly mainMenuItems = computed(() => {
const isAuthenticated = this.isAuthenticated();
const filtered = filterMenuItems(MENU_ITEMS, isAuthenticated);

Expand All @@ -63,7 +63,7 @@ export class NavMenuComponent {
return items;
});

protected readonly currentRoute = toSignal(
readonly currentRoute = toSignal(
this.router.events.pipe(
filter((event): event is NavigationEnd => event instanceof NavigationEnd),
map(() => this.getRouteInfo())
Expand All @@ -73,11 +73,11 @@ export class NavMenuComponent {
}
);

protected readonly currentResourceId = computed(() => this.currentRoute().resourceId);
protected readonly currentProviderId = computed(() => this.currentRoute().providerId);
protected readonly isCollectionsRoute = computed(() => this.currentRoute().isCollectionsWithId);
protected readonly isPreprintRoute = computed(() => this.currentRoute().isPreprintRoute);
protected readonly canUserViewReviews = select(UserSelectors.getCanViewReviews);
readonly currentResourceId = computed(() => this.currentRoute().resourceId);
readonly currentProviderId = computed(() => this.currentRoute().providerId);
readonly isCollectionsRoute = computed(() => this.currentRoute().isCollectionsWithId);
readonly isPreprintRoute = computed(() => this.currentRoute().isPreprintRoute);
readonly canUserViewReviews = select(UserSelectors.getCanViewReviews);

private getRouteInfo() {
const urlSegments = this.router.url.split('/').filter((segment) => segment);
Expand Down Expand Up @@ -115,6 +115,6 @@ export class NavMenuComponent {
}
}

protected readonly hasVisibleChildren = (item: MenuItem): boolean =>
readonly hasVisibleChildren = (item: MenuItem): boolean =>
Array.isArray(item.items) && item.items.some((child) => !!child.visible);
}
2 changes: 1 addition & 1 deletion src/app/core/components/root/root.component.html
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,4 @@
</div>
}

<p-confirm-dialog styleClass="w-full md:w-6 xl:w-5" />
<p-confirm-dialog id="dialog" styleClass="w-full md:w-6 xl:w-5" [header]="'common.dialogs.confirmation' | translate" />
3 changes: 3 additions & 0 deletions src/app/core/components/root/root.component.ts
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
import { TranslatePipe } from '@ngx-translate/core';

import { ConfirmDialog } from 'primeng/confirmdialog';

import { CommonModule } from '@angular/common';
Expand All @@ -23,6 +25,7 @@ import { IS_MEDIUM, IS_WEB } from '@osf/shared/helpers';
BreadcrumbComponent,
RouterOutlet,
SidenavComponent,
TranslatePipe,
],
templateUrl: './root.component.html',
styleUrls: ['./root.component.scss'],
Expand Down
2 changes: 1 addition & 1 deletion src/app/core/components/sidenav/sidenav.component.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<aside class="custom-scrollbar flex flex-column p-4 h-full">
<img ngSrc="assets/images/logo.svg" alt="OSF Logo" height="36" width="106" />
<osf-nav-menu class="m-t-36" />
<osf-nav-menu class="mt-5" />
</aside>
6 changes: 4 additions & 2 deletions src/app/core/constants/environment.token.ts
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import { InjectionToken } from '@angular/core';

import { AppEnvironment } from '@shared/models/environment.model';

import { environment } from 'src/environments/environment';

export const ENVIRONMENT = new InjectionToken<typeof environment>('App Environment', {
export const ENVIRONMENT = new InjectionToken<AppEnvironment>('App Environment', {
providedIn: 'root',
factory: () => environment,
factory: () => environment as AppEnvironment,
});
1 change: 0 additions & 1 deletion src/app/core/constants/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,3 @@ export * from './error-messages';
export * from './nav-items.constant';
export * from './ngxs-states.constant';
export * from './social-icons.constant';
export * from './storage-locations.constant';
29 changes: 21 additions & 8 deletions src/app/core/constants/nav-items.constant.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ export const AUTHENTICATED_MENU_ITEMS: string[] = [
'my-registrations',
'my-projects',
'my-preprints',
'registries-overview',
'settings',
];

Expand All @@ -31,14 +30,14 @@ export const PROJECT_MENU_ITEMS: MenuItem[] = [
label: 'navigation.overview',
routerLink: 'overview',
visible: true,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'project-metadata',
label: 'navigation.metadata',
routerLink: 'metadata',
visible: true,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'project-files',
Expand Down Expand Up @@ -82,6 +81,13 @@ export const PROJECT_MENU_ITEMS: MenuItem[] = [
visible: true,
routerLinkActiveOptions: { exact: true },
},
{
id: 'project-linked-services',
label: 'navigation.linkedServices',
routerLink: 'links',
visible: true,
routerLinkActiveOptions: { exact: true },
},
{
id: 'project-settings',
label: 'navigation.settings',
Expand All @@ -107,14 +113,14 @@ export const REGISTRATION_MENU_ITEMS: MenuItem[] = [
label: 'navigation.overview',
routerLink: 'overview',
visible: true,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'registration-metadata',
label: 'navigation.metadata',
routerLink: 'metadata',
visible: true,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'registration-files',
Expand Down Expand Up @@ -165,6 +171,13 @@ export const REGISTRATION_MENU_ITEMS: MenuItem[] = [
visible: true,
routerLinkActiveOptions: { exact: false },
},
{
id: 'registration-recent-activity',
label: 'navigation.recentActivity',
routerLink: 'recent-activity',
visible: true,
routerLinkActiveOptions: { exact: true },
},
];

export const MENU_ITEMS: MenuItem[] = [
Expand Down Expand Up @@ -254,14 +267,14 @@ export const MENU_ITEMS: MenuItem[] = [
routerLink: '/registries/discover',
label: 'navigation.discover',
visible: true,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'registries-moderation',
routerLink: '/registries/osf/moderation',
routerLink: '/registries',
label: 'navigation.moderation',
visible: false,
routerLinkActiveOptions: { exact: true },
routerLinkActiveOptions: { exact: false },
},
{
id: 'registry-details',
Expand Down
8 changes: 0 additions & 8 deletions src/app/core/constants/storage-locations.constant.ts

This file was deleted.

4 changes: 3 additions & 1 deletion src/app/core/guards/auth.guard.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,14 @@ import { map, switchMap, take } from 'rxjs';
import { inject } from '@angular/core';
import { CanActivateFn, Router } from '@angular/router';

import { AuthService } from '@core/services';
import { GetCurrentUser, UserSelectors } from '@osf/core/store/user';
import { hasViewOnlyParam } from '@osf/shared/helpers';

export const authGuard: CanActivateFn = () => {
const store = inject(Store);
const router = inject(Router);
const authService = inject(AuthService);

const isAuthenticated = store.selectSnapshot(UserSelectors.isAuthenticated);

Expand All @@ -28,7 +30,7 @@ export const authGuard: CanActivateFn = () => {
take(1),
map((isAuthenticated) => {
if (!isAuthenticated) {
router.navigate(['/']);
authService.navigateToSignIn();
return false;
}

Expand Down
Loading
Loading