diff --git a/src/app/app.config.ts b/src/app/app.config.ts index 9d6177c..9317cf6 100644 --- a/src/app/app.config.ts +++ b/src/app/app.config.ts @@ -3,7 +3,7 @@ import { provideRouter } from '@angular/router'; import { routes } from './app.routes'; import { provideHttpClient, withInterceptors } from '@angular/common/http'; -import { authInterceptor } from './interceptor/auth.interceptor'; +import { authInterceptor } from './shared/interceptors/auth.interceptor'; import { provideTanStackQuery, QueryClient } from '@tanstack/angular-query-experimental'; import { withDevtools } from '@tanstack/angular-query-experimental/devtools'; diff --git a/src/app/app.routes.ts b/src/app/app.routes.ts index 515b187..ad30b05 100644 --- a/src/app/app.routes.ts +++ b/src/app/app.routes.ts @@ -1,8 +1,8 @@ import { Routes } from '@angular/router'; -import { RecipePage } from './recipe-page/recipe-page'; -import { RecipesPage } from './recipes-page/recipes-page'; -import { RecipesSearchPage } from './recipes-search-page/recipes-search-page'; -import { RecipeUpload } from './recipe-upload/recipe-upload'; +import { RecipePage } from './pages/recipe-page/recipe-page'; +import { RecipesPage } from './pages/recipes-page/recipes-page'; +import { RecipesSearchPage } from './pages/recipes-search-page/recipes-search-page'; +import { RecipeUploadPage } from './pages/recipe-upload-page/recipe-upload-page'; export const routes: Routes = [ { @@ -15,7 +15,7 @@ export const routes: Routes = [ }, { path: 'recipes-upload', - component: RecipeUpload, + component: RecipeUploadPage, }, { path: 'recipes/:username/:slug', diff --git a/src/app/app.ts b/src/app/app.ts index 62f6947..40df27f 100644 --- a/src/app/app.ts +++ b/src/app/app.ts @@ -1,9 +1,9 @@ import { Component, signal } from '@angular/core'; import { RouterOutlet } from '@angular/router'; -import { Header } from './header/header'; -import { Nav } from './nav/nav'; +import { Header } from './shared/components/header/header'; +import { Nav } from './shared/components/nav/nav'; import { FontAwesomeModule } from '@fortawesome/angular-fontawesome'; -import { Footer } from './footer/footer'; +import { Footer } from './shared/components/footer/footer'; @Component({ selector: 'app-root', diff --git a/src/app/recipe-page/recipe-page-content/recipe-page-content.css b/src/app/pages/recipe-page/recipe-page-content/recipe-page-content.css similarity index 100% rename from src/app/recipe-page/recipe-page-content/recipe-page-content.css rename to src/app/pages/recipe-page/recipe-page-content/recipe-page-content.css diff --git a/src/app/recipe-page/recipe-page-content/recipe-page-content.html b/src/app/pages/recipe-page/recipe-page-content/recipe-page-content.html similarity index 100% rename from src/app/recipe-page/recipe-page-content/recipe-page-content.html rename to src/app/pages/recipe-page/recipe-page-content/recipe-page-content.html diff --git a/src/app/recipe-page/recipe-page-content/recipe-page-content.spec.ts b/src/app/pages/recipe-page/recipe-page-content/recipe-page-content.spec.ts similarity index 100% rename from src/app/recipe-page/recipe-page-content/recipe-page-content.spec.ts rename to src/app/pages/recipe-page/recipe-page-content/recipe-page-content.spec.ts diff --git a/src/app/recipe-page/recipe-page-content/recipe-page-content.ts b/src/app/pages/recipe-page/recipe-page-content/recipe-page-content.ts similarity index 79% rename from src/app/recipe-page/recipe-page-content/recipe-page-content.ts rename to src/app/pages/recipe-page/recipe-page-content/recipe-page-content.ts index 75b5373..acd44f9 100644 --- a/src/app/recipe-page/recipe-page-content/recipe-page-content.ts +++ b/src/app/pages/recipe-page/recipe-page-content/recipe-page-content.ts @@ -1,12 +1,12 @@ import { Component, computed, inject, input } from '@angular/core'; -import { RecipeView } from '../../model/Recipe.model'; +import { RecipeView } from '../../../shared/models/Recipe.model'; import { injectMutation, injectQuery } from '@tanstack/angular-query-experimental'; -import { ImageService } from '../../service/image.service'; +import { ImageService } from '../../../shared/services/image.service'; import { faGlobe, faLock, faStar, faUser } from '@fortawesome/free-solid-svg-icons'; import { FaIconComponent } from '@fortawesome/angular-fontawesome'; -import { RecipeService } from '../../service/recipe.service'; -import { AuthService } from '../../service/auth.service'; -import { RecipeCommentsList } from '../../recipe-comments-list/recipe-comments-list.component'; +import { RecipeService } from '../../../shared/services/recipe.service'; +import { AuthService } from '../../../shared/services/auth.service'; +import { RecipeCommentsList } from '../../../shared/components/recipe-comments-list/recipe-comments-list'; @Component({ selector: 'app-recipe-page-content', diff --git a/src/app/recipe-page/recipe-page.css b/src/app/pages/recipe-page/recipe-page.css similarity index 100% rename from src/app/recipe-page/recipe-page.css rename to src/app/pages/recipe-page/recipe-page.css diff --git a/src/app/recipe-page/recipe-page.html b/src/app/pages/recipe-page/recipe-page.html similarity index 100% rename from src/app/recipe-page/recipe-page.html rename to src/app/pages/recipe-page/recipe-page.html diff --git a/src/app/recipe-page/recipe-page.spec.ts b/src/app/pages/recipe-page/recipe-page.spec.ts similarity index 100% rename from src/app/recipe-page/recipe-page.spec.ts rename to src/app/pages/recipe-page/recipe-page.spec.ts diff --git a/src/app/recipe-page/recipe-page.ts b/src/app/pages/recipe-page/recipe-page.ts similarity index 92% rename from src/app/recipe-page/recipe-page.ts rename to src/app/pages/recipe-page/recipe-page.ts index 3b6fed4..e217bf1 100644 --- a/src/app/recipe-page/recipe-page.ts +++ b/src/app/pages/recipe-page/recipe-page.ts @@ -1,6 +1,6 @@ import { Component, inject } from '@angular/core'; import { ActivatedRoute } from '@angular/router'; -import { RecipeService } from '../service/recipe.service'; +import { RecipeService } from '../../shared/services/recipe.service'; import { RecipePageContent } from './recipe-page-content/recipe-page-content'; import { injectQuery } from '@tanstack/angular-query-experimental'; diff --git a/src/app/recipe-upload/recipe-upload.css b/src/app/pages/recipe-upload-page/recipe-upload-page.css similarity index 100% rename from src/app/recipe-upload/recipe-upload.css rename to src/app/pages/recipe-upload-page/recipe-upload-page.css diff --git a/src/app/recipe-upload/recipe-upload.html b/src/app/pages/recipe-upload-page/recipe-upload-page.html similarity index 100% rename from src/app/recipe-upload/recipe-upload.html rename to src/app/pages/recipe-upload-page/recipe-upload-page.html diff --git a/src/app/recipe-upload/recipe-upload.spec.ts b/src/app/pages/recipe-upload-page/recipe-upload-page.spec.ts similarity index 60% rename from src/app/recipe-upload/recipe-upload.spec.ts rename to src/app/pages/recipe-upload-page/recipe-upload-page.spec.ts index a8eb3ec..800feda 100644 --- a/src/app/recipe-upload/recipe-upload.spec.ts +++ b/src/app/pages/recipe-upload-page/recipe-upload-page.spec.ts @@ -1,17 +1,17 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { RecipeUpload } from './recipe-upload'; +import { RecipeUploadPage } from './recipe-upload-page'; describe('RecipeUpload', () => { - let component: RecipeUpload; - let fixture: ComponentFixture; + let component: RecipeUploadPage; + let fixture: ComponentFixture; beforeEach(async () => { await TestBed.configureTestingModule({ - imports: [RecipeUpload], + imports: [RecipeUploadPage], }).compileComponents(); - fixture = TestBed.createComponent(RecipeUpload); + fixture = TestBed.createComponent(RecipeUploadPage); component = fixture.componentInstance; await fixture.whenStable(); }); diff --git a/src/app/recipe-upload/recipe-upload.ts b/src/app/pages/recipe-upload-page/recipe-upload-page.ts similarity index 93% rename from src/app/recipe-upload/recipe-upload.ts rename to src/app/pages/recipe-upload-page/recipe-upload-page.ts index b26e576..188d0fd 100644 --- a/src/app/recipe-upload/recipe-upload.ts +++ b/src/app/pages/recipe-upload-page/recipe-upload-page.ts @@ -7,15 +7,15 @@ import { Validators, } from '@angular/forms'; import { SseClient } from 'ngx-sse-client'; -import { Spinner } from '../spinner/spinner'; +import { Spinner } from '../../shared/components/spinner/spinner'; @Component({ - selector: 'app-recipe-upload', + selector: 'app-recipe-upload-page', imports: [ReactiveFormsModule, Spinner], - templateUrl: './recipe-upload.html', - styleUrl: './recipe-upload.css', + templateUrl: './recipe-upload-page.html', + styleUrl: './recipe-upload-page.css', }) -export class RecipeUpload { +export class RecipeUploadPage { private readonly sseClient = inject(SseClient); private readonly formBuilder = inject(FormBuilder); diff --git a/src/app/recipes-page/recipes-page.css b/src/app/pages/recipes-page/recipes-page.css similarity index 100% rename from src/app/recipes-page/recipes-page.css rename to src/app/pages/recipes-page/recipes-page.css diff --git a/src/app/recipes-page/recipes-page.html b/src/app/pages/recipes-page/recipes-page.html similarity index 100% rename from src/app/recipes-page/recipes-page.html rename to src/app/pages/recipes-page/recipes-page.html diff --git a/src/app/recipes-page/recipes-page.spec.ts b/src/app/pages/recipes-page/recipes-page.spec.ts similarity index 100% rename from src/app/recipes-page/recipes-page.spec.ts rename to src/app/pages/recipes-page/recipes-page.spec.ts diff --git a/src/app/recipes-page/recipes-page.ts b/src/app/pages/recipes-page/recipes-page.ts similarity index 76% rename from src/app/recipes-page/recipes-page.ts rename to src/app/pages/recipes-page/recipes-page.ts index f48faf8..b42007e 100644 --- a/src/app/recipes-page/recipes-page.ts +++ b/src/app/pages/recipes-page/recipes-page.ts @@ -1,7 +1,7 @@ import { Component, inject } from '@angular/core'; -import { RecipeService } from '../service/recipe.service'; +import { RecipeService } from '../../shared/services/recipe.service'; import { injectQuery } from '@tanstack/angular-query-experimental'; -import { RecipeCardGrid } from '../recipe-card-grid/recipe-card-grid'; +import { RecipeCardGrid } from '../../shared/components/recipe-card-grid/recipe-card-grid'; @Component({ selector: 'app-recipes-page', diff --git a/src/app/recipes-search-page/recipes-search-page.css b/src/app/pages/recipes-search-page/recipes-search-page.css similarity index 100% rename from src/app/recipes-search-page/recipes-search-page.css rename to src/app/pages/recipes-search-page/recipes-search-page.css diff --git a/src/app/recipes-search-page/recipes-search-page.html b/src/app/pages/recipes-search-page/recipes-search-page.html similarity index 100% rename from src/app/recipes-search-page/recipes-search-page.html rename to src/app/pages/recipes-search-page/recipes-search-page.html diff --git a/src/app/recipes-search-page/recipes-search-page.spec.ts b/src/app/pages/recipes-search-page/recipes-search-page.spec.ts similarity index 100% rename from src/app/recipes-search-page/recipes-search-page.spec.ts rename to src/app/pages/recipes-search-page/recipes-search-page.spec.ts diff --git a/src/app/recipes-search-page/recipes-search-page.ts b/src/app/pages/recipes-search-page/recipes-search-page.ts similarity index 91% rename from src/app/recipes-search-page/recipes-search-page.ts rename to src/app/pages/recipes-search-page/recipes-search-page.ts index ab8c94a..de66314 100644 --- a/src/app/recipes-search-page/recipes-search-page.ts +++ b/src/app/pages/recipes-search-page/recipes-search-page.ts @@ -1,8 +1,8 @@ import { Component, inject, signal } from '@angular/core'; import { FormControl, FormGroup, ReactiveFormsModule, Validators } from '@angular/forms'; import { injectQuery } from '@tanstack/angular-query-experimental'; -import { RecipeService } from '../service/recipe.service'; -import { RecipeCardGrid } from '../recipe-card-grid/recipe-card-grid'; +import { RecipeService } from '../../shared/services/recipe.service'; +import { RecipeCardGrid } from '../../shared/components/recipe-card-grid/recipe-card-grid'; import { ActivatedRoute, Router } from '@angular/router'; @Component({ diff --git a/src/app/footer/footer.css b/src/app/shared/components/footer/footer.css similarity index 100% rename from src/app/footer/footer.css rename to src/app/shared/components/footer/footer.css diff --git a/src/app/footer/footer.html b/src/app/shared/components/footer/footer.html similarity index 100% rename from src/app/footer/footer.html rename to src/app/shared/components/footer/footer.html diff --git a/src/app/footer/footer.spec.ts b/src/app/shared/components/footer/footer.spec.ts similarity index 100% rename from src/app/footer/footer.spec.ts rename to src/app/shared/components/footer/footer.spec.ts diff --git a/src/app/footer/footer.ts b/src/app/shared/components/footer/footer.ts similarity index 100% rename from src/app/footer/footer.ts rename to src/app/shared/components/footer/footer.ts diff --git a/src/app/header/header.css b/src/app/shared/components/header/header.css similarity index 100% rename from src/app/header/header.css rename to src/app/shared/components/header/header.css diff --git a/src/app/header/header.html b/src/app/shared/components/header/header.html similarity index 100% rename from src/app/header/header.html rename to src/app/shared/components/header/header.html diff --git a/src/app/header/header.spec.ts b/src/app/shared/components/header/header.spec.ts similarity index 100% rename from src/app/header/header.spec.ts rename to src/app/shared/components/header/header.spec.ts diff --git a/src/app/header/header.ts b/src/app/shared/components/header/header.ts similarity index 91% rename from src/app/header/header.ts rename to src/app/shared/components/header/header.ts index 4b58b96..29bfa4b 100644 --- a/src/app/header/header.ts +++ b/src/app/shared/components/header/header.ts @@ -1,5 +1,5 @@ import { Component, computed, inject } from '@angular/core'; -import { AuthService } from '../service/auth.service'; +import { AuthService } from '../../services/auth.service'; @Component({ selector: 'app-header', diff --git a/src/app/nav/nav.css b/src/app/shared/components/nav/nav.css similarity index 100% rename from src/app/nav/nav.css rename to src/app/shared/components/nav/nav.css diff --git a/src/app/nav/nav.html b/src/app/shared/components/nav/nav.html similarity index 100% rename from src/app/nav/nav.html rename to src/app/shared/components/nav/nav.html diff --git a/src/app/nav/nav.spec.ts b/src/app/shared/components/nav/nav.spec.ts similarity index 100% rename from src/app/nav/nav.spec.ts rename to src/app/shared/components/nav/nav.spec.ts diff --git a/src/app/nav/nav.ts b/src/app/shared/components/nav/nav.ts similarity index 100% rename from src/app/nav/nav.ts rename to src/app/shared/components/nav/nav.ts diff --git a/src/app/recipe-card-grid/recipe-card-grid.css b/src/app/shared/components/recipe-card-grid/recipe-card-grid.css similarity index 100% rename from src/app/recipe-card-grid/recipe-card-grid.css rename to src/app/shared/components/recipe-card-grid/recipe-card-grid.css diff --git a/src/app/recipe-card-grid/recipe-card-grid.html b/src/app/shared/components/recipe-card-grid/recipe-card-grid.html similarity index 100% rename from src/app/recipe-card-grid/recipe-card-grid.html rename to src/app/shared/components/recipe-card-grid/recipe-card-grid.html diff --git a/src/app/recipe-card-grid/recipe-card-grid.spec.ts b/src/app/shared/components/recipe-card-grid/recipe-card-grid.spec.ts similarity index 100% rename from src/app/recipe-card-grid/recipe-card-grid.spec.ts rename to src/app/shared/components/recipe-card-grid/recipe-card-grid.spec.ts diff --git a/src/app/recipe-card-grid/recipe-card-grid.ts b/src/app/shared/components/recipe-card-grid/recipe-card-grid.ts similarity index 87% rename from src/app/recipe-card-grid/recipe-card-grid.ts rename to src/app/shared/components/recipe-card-grid/recipe-card-grid.ts index 046baf9..63ebc78 100644 --- a/src/app/recipe-card-grid/recipe-card-grid.ts +++ b/src/app/shared/components/recipe-card-grid/recipe-card-grid.ts @@ -1,6 +1,6 @@ import { Component, input } from '@angular/core'; import { RecipeCard } from './recipe-card/recipe-card'; -import { Recipe } from '../model/Recipe.model'; +import { Recipe } from '../../models/Recipe.model'; @Component({ selector: 'app-recipe-card-grid', diff --git a/src/app/recipe-card-grid/recipe-card/recipe-card.css b/src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.css similarity index 100% rename from src/app/recipe-card-grid/recipe-card/recipe-card.css rename to src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.css diff --git a/src/app/recipe-card-grid/recipe-card/recipe-card.html b/src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.html similarity index 100% rename from src/app/recipe-card-grid/recipe-card/recipe-card.html rename to src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.html diff --git a/src/app/recipe-card-grid/recipe-card/recipe-card.spec.ts b/src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.spec.ts similarity index 100% rename from src/app/recipe-card-grid/recipe-card/recipe-card.spec.ts rename to src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.spec.ts diff --git a/src/app/recipe-card-grid/recipe-card/recipe-card.ts b/src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.ts similarity index 91% rename from src/app/recipe-card-grid/recipe-card/recipe-card.ts rename to src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.ts index 5a81d6d..81c9668 100644 --- a/src/app/recipe-card-grid/recipe-card/recipe-card.ts +++ b/src/app/shared/components/recipe-card-grid/recipe-card/recipe-card.ts @@ -1,8 +1,8 @@ import { Component, computed, inject, input } from '@angular/core'; -import { Recipe } from '../../model/Recipe.model'; +import { Recipe } from '../../../models/Recipe.model'; import { RouterLink } from '@angular/router'; import { injectQuery } from '@tanstack/angular-query-experimental'; -import { ImageService } from '../../service/image.service'; +import { ImageService } from '../../../services/image.service'; import { faGlobe, faLock, faStar, faUser } from '@fortawesome/free-solid-svg-icons'; import { FaIconComponent } from '@fortawesome/angular-fontawesome'; diff --git a/src/app/recipe-comments-list/recipe-comments-list.component.css b/src/app/shared/components/recipe-comments-list/recipe-comments-list.css similarity index 100% rename from src/app/recipe-comments-list/recipe-comments-list.component.css rename to src/app/shared/components/recipe-comments-list/recipe-comments-list.css diff --git a/src/app/recipe-comments-list/recipe-comments-list.component.html b/src/app/shared/components/recipe-comments-list/recipe-comments-list.html similarity index 100% rename from src/app/recipe-comments-list/recipe-comments-list.component.html rename to src/app/shared/components/recipe-comments-list/recipe-comments-list.html diff --git a/src/app/recipe-comments-list/recipe-comments-list.component.spec.ts b/src/app/shared/components/recipe-comments-list/recipe-comments-list.spec.ts similarity index 89% rename from src/app/recipe-comments-list/recipe-comments-list.component.spec.ts rename to src/app/shared/components/recipe-comments-list/recipe-comments-list.spec.ts index aa27e51..abd99ed 100644 --- a/src/app/recipe-comments-list/recipe-comments-list.component.spec.ts +++ b/src/app/shared/components/recipe-comments-list/recipe-comments-list.spec.ts @@ -1,6 +1,6 @@ import { ComponentFixture, TestBed } from '@angular/core/testing'; -import { RecipeCommentsList } from './recipe-comments-list.component'; +import { RecipeCommentsList } from './recipe-comments-list'; describe('CommentsList', () => { let component: RecipeCommentsList; diff --git a/src/app/recipe-comments-list/recipe-comments-list.component.ts b/src/app/shared/components/recipe-comments-list/recipe-comments-list.ts similarity index 84% rename from src/app/recipe-comments-list/recipe-comments-list.component.ts rename to src/app/shared/components/recipe-comments-list/recipe-comments-list.ts index fc160a8..66ac677 100644 --- a/src/app/recipe-comments-list/recipe-comments-list.component.ts +++ b/src/app/shared/components/recipe-comments-list/recipe-comments-list.ts @@ -1,16 +1,16 @@ import { Component, computed, inject, input } from '@angular/core'; import { FormControl, FormGroup, ReactiveFormsModule, Validators } from '@angular/forms'; -import { RecipeService } from '../service/recipe.service'; +import { RecipeService } from '../../services/recipe.service'; import { injectInfiniteQuery, injectMutation } from '@tanstack/angular-query-experimental'; -import { AuthService } from '../service/auth.service'; -import { RecipeComments } from '../model/RecipeComment.model'; -import { DateTimeFormatPipe } from '../pipe/dateTimeFormat.pipe'; +import { AuthService } from '../../services/auth.service'; +import { RecipeComments } from '../../models/RecipeComment.model'; +import { DateTimeFormatPipe } from '../../pipes/dateTimeFormat.pipe'; @Component({ selector: 'app-comments-list', imports: [ReactiveFormsModule, DateTimeFormatPipe], - templateUrl: './recipe-comments-list.component.html', - styleUrl: './recipe-comments-list.component.css', + templateUrl: './recipe-comments-list.html', + styleUrl: './recipe-comments-list.css', }) export class RecipeCommentsList { public readonly recipeUsername = input.required(); diff --git a/src/app/spinner/spinner.css b/src/app/shared/components/spinner/spinner.css similarity index 100% rename from src/app/spinner/spinner.css rename to src/app/shared/components/spinner/spinner.css diff --git a/src/app/spinner/spinner.html b/src/app/shared/components/spinner/spinner.html similarity index 100% rename from src/app/spinner/spinner.html rename to src/app/shared/components/spinner/spinner.html diff --git a/src/app/spinner/spinner.spec.ts b/src/app/shared/components/spinner/spinner.spec.ts similarity index 100% rename from src/app/spinner/spinner.spec.ts rename to src/app/shared/components/spinner/spinner.spec.ts diff --git a/src/app/spinner/spinner.ts b/src/app/shared/components/spinner/spinner.ts similarity index 100% rename from src/app/spinner/spinner.ts rename to src/app/shared/components/spinner/spinner.ts diff --git a/src/app/interceptor/auth.interceptor.ts b/src/app/shared/interceptors/auth.interceptor.ts similarity index 97% rename from src/app/interceptor/auth.interceptor.ts rename to src/app/shared/interceptors/auth.interceptor.ts index c886d10..6b27da8 100644 --- a/src/app/interceptor/auth.interceptor.ts +++ b/src/app/shared/interceptors/auth.interceptor.ts @@ -1,6 +1,6 @@ import { HttpErrorResponse, HttpInterceptorFn } from '@angular/common/http'; import { inject } from '@angular/core'; -import { AuthService } from '../service/auth.service'; +import { AuthService } from '../services/auth.service'; import { catchError, from, switchMap, throwError } from 'rxjs'; import { Router } from '@angular/router'; diff --git a/src/app/model/ImageView.model.ts b/src/app/shared/models/ImageView.model.ts similarity index 100% rename from src/app/model/ImageView.model.ts rename to src/app/shared/models/ImageView.model.ts diff --git a/src/app/model/LoginView.model.ts b/src/app/shared/models/LoginView.model.ts similarity index 100% rename from src/app/model/LoginView.model.ts rename to src/app/shared/models/LoginView.model.ts diff --git a/src/app/model/Query.model.ts b/src/app/shared/models/Query.model.ts similarity index 100% rename from src/app/model/Query.model.ts rename to src/app/shared/models/Query.model.ts diff --git a/src/app/model/Recipe.model.ts b/src/app/shared/models/Recipe.model.ts similarity index 100% rename from src/app/model/Recipe.model.ts rename to src/app/shared/models/Recipe.model.ts diff --git a/src/app/model/RecipeComment.model.ts b/src/app/shared/models/RecipeComment.model.ts similarity index 100% rename from src/app/model/RecipeComment.model.ts rename to src/app/shared/models/RecipeComment.model.ts diff --git a/src/app/model/ResourceOwner.model.ts b/src/app/shared/models/ResourceOwner.model.ts similarity index 100% rename from src/app/model/ResourceOwner.model.ts rename to src/app/shared/models/ResourceOwner.model.ts diff --git a/src/app/model/SliceView.model.ts b/src/app/shared/models/SliceView.model.ts similarity index 100% rename from src/app/model/SliceView.model.ts rename to src/app/shared/models/SliceView.model.ts diff --git a/src/app/pipe/dateTimeFormat.pipe.ts b/src/app/shared/pipes/dateTimeFormat.pipe.ts similarity index 84% rename from src/app/pipe/dateTimeFormat.pipe.ts rename to src/app/shared/pipes/dateTimeFormat.pipe.ts index c05f698..42c2935 100644 --- a/src/app/pipe/dateTimeFormat.pipe.ts +++ b/src/app/shared/pipes/dateTimeFormat.pipe.ts @@ -1,5 +1,5 @@ import { inject, Pipe, PipeTransform } from '@angular/core'; -import { DateService } from '../service/date.service'; +import { DateService } from '../services/date.service'; @Pipe({ name: 'dateTimeFormat', diff --git a/src/app/service/auth.service.spec.ts b/src/app/shared/services/auth.service.spec.ts similarity index 100% rename from src/app/service/auth.service.spec.ts rename to src/app/shared/services/auth.service.spec.ts diff --git a/src/app/service/auth.service.ts b/src/app/shared/services/auth.service.ts similarity index 97% rename from src/app/service/auth.service.ts rename to src/app/shared/services/auth.service.ts index b75af77..41e0150 100644 --- a/src/app/service/auth.service.ts +++ b/src/app/shared/services/auth.service.ts @@ -1,6 +1,6 @@ import { inject, Injectable, Signal, signal } from '@angular/core'; import { HttpClient } from '@angular/common/http'; -import { LoginView } from '../model/LoginView.model'; +import { LoginView } from '../models/LoginView.model'; import { firstValueFrom, Observable, tap } from 'rxjs'; import { QueryClient } from '@tanstack/angular-query-experimental'; import { Router } from '@angular/router'; diff --git a/src/app/service/date.service.ts b/src/app/shared/services/date.service.ts similarity index 100% rename from src/app/service/date.service.ts rename to src/app/shared/services/date.service.ts diff --git a/src/app/service/endpoint.service.ts b/src/app/shared/services/endpoint.service.ts similarity index 93% rename from src/app/service/endpoint.service.ts rename to src/app/shared/services/endpoint.service.ts index 25327ff..f2ebc7c 100644 --- a/src/app/service/endpoint.service.ts +++ b/src/app/shared/services/endpoint.service.ts @@ -1,6 +1,6 @@ import { Injectable } from '@angular/core'; -import { Endpoints } from '../endpoints'; -import { QueryParams } from '../model/Query.model'; +import { Endpoints } from '../../endpoints'; +import { QueryParams } from '../models/Query.model'; @Injectable({ providedIn: 'root', diff --git a/src/app/service/image.service.ts b/src/app/shared/services/image.service.ts similarity index 100% rename from src/app/service/image.service.ts rename to src/app/shared/services/image.service.ts diff --git a/src/app/service/recipe.service.spec.ts b/src/app/shared/services/recipe.service.spec.ts similarity index 100% rename from src/app/service/recipe.service.spec.ts rename to src/app/shared/services/recipe.service.spec.ts diff --git a/src/app/service/recipe.service.ts b/src/app/shared/services/recipe.service.ts similarity index 93% rename from src/app/service/recipe.service.ts rename to src/app/shared/services/recipe.service.ts index 2aa285d..f9e79f7 100644 --- a/src/app/service/recipe.service.ts +++ b/src/app/shared/services/recipe.service.ts @@ -1,11 +1,11 @@ import { inject, Injectable } from '@angular/core'; import { HttpClient } from '@angular/common/http'; import { firstValueFrom, lastValueFrom, map } from 'rxjs'; -import { Recipe, RecipeInfoViews, RecipeView } from '../model/Recipe.model'; +import { Recipe, RecipeInfoViews, RecipeView } from '../models/Recipe.model'; import { AuthService } from './auth.service'; import { QueryClient } from '@tanstack/angular-query-experimental'; -import { RecipeComment, RecipeComments } from '../model/RecipeComment.model'; -import { QueryParams } from '../model/Query.model'; +import { RecipeComment, RecipeComments } from '../models/RecipeComment.model'; +import { QueryParams } from '../models/Query.model'; import { EndpointService } from './endpoint.service'; @Injectable({