diff --git a/bizmatch-client/.postcssrc.json b/bizmatch-client/.postcssrc.json new file mode 100644 index 0000000..9674304 --- /dev/null +++ b/bizmatch-client/.postcssrc.json @@ -0,0 +1,5 @@ +{ + "plugins": { + "@tailwindcss/postcss": {} + } +} \ No newline at end of file diff --git a/bizmatch-client/package.json b/bizmatch-client/package.json index 3de7c2a..425a1ac 100644 --- a/bizmatch-client/package.json +++ b/bizmatch-client/package.json @@ -3,7 +3,7 @@ "version": "0.0.0", "scripts": { "ng": "ng", - "start": "ng serve", + "start": "ng serve --host 0.0.0.0", "build": "ng build", "watch": "ng build --watch --configuration development", "test": "ng test", @@ -29,6 +29,7 @@ "@fortawesome/free-solid-svg-icons": "^6.7.2", "@ng-select/ng-select": "^14.2.6", "@ngneat/until-destroy": "^10.0.0", + "@tailwindcss/postcss": "^4.1.3", "browser-bunyan": "^1.8.0", "dayjs": "^1.11.13", "express": "^4.18.2", @@ -40,7 +41,9 @@ "ngx-quill": "^27.0.1", "ngx-sharebuttons": "^17.0.0", "on-change": "^5.0.1", + "postcss": "^8.5.3", "rxjs": "~7.8.0", + "tailwindcss": "^4.1.3", "tslib": "^2.3.0", "urlcat": "^3.1.0", "zone.js": "~0.15.0" @@ -52,15 +55,12 @@ "@types/express": "^4.17.17", "@types/jasmine": "~5.1.0", "@types/node": "^18.18.0", - "autoprefixer": "^10.4.21", "jasmine-core": "~5.6.0", "karma": "~6.4.0", "karma-chrome-launcher": "~3.2.0", "karma-coverage": "~2.2.0", "karma-jasmine": "~5.1.0", "karma-jasmine-html-reporter": "~2.1.0", - "postcss": "^8.5.3", - "tailwindcss": "^3.4.17", "typescript": "~5.7.2" } -} +} \ No newline at end of file diff --git a/bizmatch-client/src/app/components/footer/footer.component.ts b/bizmatch-client/src/app/components/footer/footer.component.ts index a7b9c47..22a7961 100644 --- a/bizmatch-client/src/app/components/footer/footer.component.ts +++ b/bizmatch-client/src/app/components/footer/footer.component.ts @@ -1,8 +1,9 @@ import { CommonModule } from '@angular/common'; import { Component } from '@angular/core'; import { FormsModule } from '@angular/forms'; -import { Router, RouterModule } from '@angular/router'; +import { NavigationEnd, Router, RouterModule } from '@angular/router'; import { FontAwesomeModule } from '@fortawesome/angular-fontawesome'; +import { initFlowbite } from 'flowbite'; @Component({ selector: 'app-footer', @@ -17,5 +18,11 @@ export class FooterComponent { currentYear: number = new Date().getFullYear(); isHomeRoute = false; constructor(private router: Router) {} - ngOnInit() {} + ngOnInit() { + this.router.events.subscribe(event => { + if (event instanceof NavigationEnd) { + initFlowbite(); + } + }); + } } diff --git a/bizmatch-client/src/app/components/header/header.component.html b/bizmatch-client/src/app/components/header/header.component.html index 2b7ebc6..2c05c8d 100644 --- a/bizmatch-client/src/app/components/header/header.component.html +++ b/bizmatch-client/src/app/components/header/header.component.html @@ -37,67 +37,79 @@ } - - - @if(user){ - - } @else { - - } diff --git a/bizmatch-client/src/app/components/header/header.component.ts b/bizmatch-client/src/app/components/header/header.component.ts index 688763f..52a2500 100644 --- a/bizmatch-client/src/app/components/header/header.component.ts +++ b/bizmatch-client/src/app/components/header/header.component.ts @@ -49,6 +49,7 @@ export class HeaderComponent { sortByOptions: KeyValueAsSortBy[] = []; numberOfBroker$: Observable; numberOfCommercial$: Observable; + userMenuVisible: boolean = false; constructor( private router: Router, private userService: UserService, @@ -68,7 +69,19 @@ export class HeaderComponent { this.sortDropdownVisible = false; } } + @HostListener('document:click', ['$event']) + handleOutsideClick(event: Event) { + const target = event.target as HTMLElement; + // Schließe das User-Menü, wenn außerhalb geklickt wird + if (this.userMenuVisible && !target.closest('#user-menu-button') && !target.closest('#user-menu-dropdown')) { + this.userMenuVisible = false; + } + } async ngOnInit() { + this.router.events.subscribe(event => { + if (event instanceof NavigationEnd) { + } + }); const token = await this.authService.getToken(); this.keycloakUser = map2User(token); if (this.keycloakUser) { @@ -194,6 +207,9 @@ export class HeaderComponent { toggleSortDropdown() { this.sortDropdownVisible = !this.sortDropdownVisible; } + toggleUserMenu() { + this.userMenuVisible = !this.userMenuVisible; + } get isProfessional() { return this.user?.customerType === 'professional'; } diff --git a/bizmatch-client/src/app/pages/business-listings/business-listings.component.html b/bizmatch-client/src/app/pages/business-listings/business-listings.component.html index e61bbb2..ea19ef2 100644 --- a/bizmatch-client/src/app/pages/business-listings/business-listings.component.html +++ b/bizmatch-client/src/app/pages/business-listings/business-listings.component.html @@ -6,10 +6,11 @@
-
- +
+ Image + - {{ selectOptions.getBusiness(listing.type) }} + {{ selectOptions.getBusiness(listing.type) }}

@@ -40,7 +41,7 @@ Company logo
-

diff --git a/bizmatch-client/src/assets/images/advertising.png b/bizmatch-client/src/assets/images/advertising.png new file mode 100644 index 0000000..8a0fa16 Binary files /dev/null and b/bizmatch-client/src/assets/images/advertising.png differ diff --git a/bizmatch-client/src/assets/images/agriculture.png b/bizmatch-client/src/assets/images/agriculture.png new file mode 100644 index 0000000..6f6d7d4 Binary files /dev/null and b/bizmatch-client/src/assets/images/agriculture.png differ diff --git a/bizmatch-client/src/assets/images/automotive.png b/bizmatch-client/src/assets/images/automotive.png new file mode 100644 index 0000000..d8eb84c Binary files /dev/null and b/bizmatch-client/src/assets/images/automotive.png differ diff --git a/bizmatch-client/src/assets/images/automotive_.png b/bizmatch-client/src/assets/images/automotive_.png new file mode 100644 index 0000000..b9d8a65 Binary files /dev/null and b/bizmatch-client/src/assets/images/automotive_.png differ diff --git a/bizmatch-client/src/assets/images/foodAndRestaurant.png b/bizmatch-client/src/assets/images/foodAndRestaurant.png new file mode 100644 index 0000000..36e425e Binary files /dev/null and b/bizmatch-client/src/assets/images/foodAndRestaurant.png differ diff --git a/bizmatch-client/src/assets/images/franchise.png b/bizmatch-client/src/assets/images/franchise.png new file mode 100644 index 0000000..2356f15 Binary files /dev/null and b/bizmatch-client/src/assets/images/franchise.png differ diff --git a/bizmatch-client/src/assets/images/industrialServices.png b/bizmatch-client/src/assets/images/industrialServices.png new file mode 100644 index 0000000..3263084 Binary files /dev/null and b/bizmatch-client/src/assets/images/industrialServices.png differ diff --git a/bizmatch-client/src/assets/images/manufacturing.png b/bizmatch-client/src/assets/images/manufacturing.png new file mode 100644 index 0000000..a8793af Binary files /dev/null and b/bizmatch-client/src/assets/images/manufacturing.png differ diff --git a/bizmatch-client/src/assets/images/oilfield.png b/bizmatch-client/src/assets/images/oilfield.png new file mode 100644 index 0000000..148097a Binary files /dev/null and b/bizmatch-client/src/assets/images/oilfield.png differ diff --git a/bizmatch-client/src/assets/images/professional.png b/bizmatch-client/src/assets/images/professional.png new file mode 100644 index 0000000..d5b4e0f Binary files /dev/null and b/bizmatch-client/src/assets/images/professional.png differ diff --git a/bizmatch-client/src/assets/images/realEstate.png b/bizmatch-client/src/assets/images/realEstate.png new file mode 100644 index 0000000..6d3ab9c Binary files /dev/null and b/bizmatch-client/src/assets/images/realEstate.png differ diff --git a/bizmatch-client/src/assets/images/retail.png b/bizmatch-client/src/assets/images/retail.png new file mode 100644 index 0000000..abc9148 Binary files /dev/null and b/bizmatch-client/src/assets/images/retail.png differ diff --git a/bizmatch-client/src/assets/images/service.png b/bizmatch-client/src/assets/images/service.png new file mode 100644 index 0000000..2e68e9b Binary files /dev/null and b/bizmatch-client/src/assets/images/service.png differ diff --git a/bizmatch-client/src/assets/images/uncategorized.png b/bizmatch-client/src/assets/images/uncategorized.png new file mode 100644 index 0000000..4feead5 Binary files /dev/null and b/bizmatch-client/src/assets/images/uncategorized.png differ diff --git a/bizmatch-client/src/cropped-Favicon-180x180.png b/bizmatch-client/src/cropped-Favicon-180x180.png new file mode 100644 index 0000000..b6f9bec Binary files /dev/null and b/bizmatch-client/src/cropped-Favicon-180x180.png differ diff --git a/bizmatch-client/src/cropped-Favicon-192x192.png b/bizmatch-client/src/cropped-Favicon-192x192.png new file mode 100644 index 0000000..1f39802 Binary files /dev/null and b/bizmatch-client/src/cropped-Favicon-192x192.png differ diff --git a/bizmatch-client/src/cropped-Favicon-32x32.png b/bizmatch-client/src/cropped-Favicon-32x32.png new file mode 100644 index 0000000..f4489b4 Binary files /dev/null and b/bizmatch-client/src/cropped-Favicon-32x32.png differ diff --git a/bizmatch-client/src/index.html b/bizmatch-client/src/index.html index 42fb79c..4d33945 100644 --- a/bizmatch-client/src/index.html +++ b/bizmatch-client/src/index.html @@ -1,13 +1,32 @@ - + - - - BizmatchClient - - - - - - - + + Bizmatch - Find Business for sale + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/bizmatch-client/src/styles.scss b/bizmatch-client/src/styles.scss index 7985189..812bb97 100644 --- a/bizmatch-client/src/styles.scss +++ b/bizmatch-client/src/styles.scss @@ -1,19 +1,34 @@ +@import '@ng-select/ng-select/themes/default.theme.css'; @import url('https://fonts.googleapis.com/css?family=Open+Sans&display=swap'); @import '@fortawesome/fontawesome-free/css/all.min.css'; -@import 'tailwindcss/base.css'; -@import 'tailwindcss/components.css'; -@import 'tailwindcss/utilities.css'; +@import 'tailwindcss'; @import 'ngx-sharebuttons/themes/default'; +@config "../tailwind.config.js"; +.color-automotive { + color: #00bc7d; +} +.color-franchise { + color: #c27aff; +} +.color-service { + color: #16bdca; +} +.color-foodAndRestaurant { + color: #b45309; +} +.color-manufacturing { + color: #f98080; +} :root { --text-color-secondary: rgba(255, 255, 255); --wrapper-width: 1491px; // --secondary-color: #ffffff; /* Setzt die secondary Farbe auf weiß */ } -.p-button.p-button-secondary.p-button-outlined { - color: #ffffff; +button { + cursor: pointer; } html, body, diff --git a/bizmatch-client/tailwind.config.js b/bizmatch-client/tailwind.config.js index 3d0bc83..141ffef 100644 --- a/bizmatch-client/tailwind.config.js +++ b/bizmatch-client/tailwind.config.js @@ -1,3 +1,4 @@ +/** @type {import('tailwindcss').Config} */ module.exports = { safelist: [ 'text-red-400', diff --git a/bizmatch/package.json b/bizmatch/package.json index f5cd830..f7f657e 100644 --- a/bizmatch/package.json +++ b/bizmatch/package.json @@ -3,7 +3,7 @@ "version": "0.0.1", "scripts": { "ng": "ng", - "start": "ng serve --host 0.0.0.0 & http-server ../bizmatch-server", + "start": "ng serve --port=4300 --host 0.0.0.0 & http-server ../bizmatch-server", "prebuild": "node version.js", "build": "node version.js && ng build", "build.dev": "node version.js && ng build --configuration dev --output-hashing=all", @@ -76,4 +76,4 @@ "tailwindcss": "^3.4.4", "typescript": "~5.4.5" } -} +} \ No newline at end of file