From 63f98a48ed8aa898dc705a99e00e5ca1f688368d Mon Sep 17 00:00:00 2001 From: Tykayn Date: Tue, 23 Sep 2025 18:30:15 +0200 Subject: [PATCH] up similar cases documents --- .../projects/sae-lib/buttons/copy/copy.html | 2 +- .../projects/sae-lib/buttons/copy/copy.scss | 13 +++++++++ .../sae-lib/chatbot/bot-talks/bot-talks.html | 28 ++++++++++-------- .../sae-lib/chatbot/bot-talks/bot-talks.scss | 27 ++++++++++++++--- .../filters/filters-group/filters-group.html | 21 +++++--------- .../filters/filters-group/filters-group.scss | 2 +- .../sae-lib/src/styles/_variables.scss | 2 ++ sae-csc/src/app/pages/main/main.html | 3 +- sae-csc/src/app/pages/main/main.ts | 3 +- .../pages/similar-cases/similar-cases.html | 29 ++++++++++--------- .../app/pages/similar-cases/similar-cases.ts | 2 ++ .../bottom-navigation/bottom-navigation.html | 26 ++++++++++------- .../bottom-navigation/bottom-navigation.scss | 7 +++-- .../translate-texts/translate-texts.html | 6 ++-- .../translate-texts/translate-texts.scss | 18 ++++++++---- .../shared/translate-texts/translate-texts.ts | 27 ++++++++++++----- .../src/styles/app/styles/pages/_main.scss | 2 +- 17 files changed, 142 insertions(+), 76 deletions(-) diff --git a/my-workspace/projects/sae-lib/buttons/copy/copy.html b/my-workspace/projects/sae-lib/buttons/copy/copy.html index 2aa2aab..693de52 100644 --- a/my-workspace/projects/sae-lib/buttons/copy/copy.html +++ b/my-workspace/projects/sae-lib/buttons/copy/copy.html @@ -1,5 +1,5 @@ } - } - - + + - + + } diff --git a/my-workspace/projects/sae-lib/filters/filters-group/filters-group.scss b/my-workspace/projects/sae-lib/filters/filters-group/filters-group.scss index a5fa52b..73a55b7 100644 --- a/my-workspace/projects/sae-lib/filters/filters-group/filters-group.scss +++ b/my-workspace/projects/sae-lib/filters/filters-group/filters-group.scss @@ -72,7 +72,7 @@ .chips-column { padding: 12px 12px; width: 220px; - border: solid 1px #ccc; + //border: solid 1px #ccc; } diff --git a/my-workspace/projects/sae-lib/src/styles/_variables.scss b/my-workspace/projects/sae-lib/src/styles/_variables.scss index 66fcc2a..41f7f61 100644 --- a/my-workspace/projects/sae-lib/src/styles/_variables.scss +++ b/my-workspace/projects/sae-lib/src/styles/_variables.scss @@ -94,6 +94,8 @@ $gradient-intense: #1e4a72; $csc-light-yellow-color: #FFF3D8; $csc-magic-color: #a86FCD; +$csc-copy-color: $ia-color-200; + $csc-bg-color: #F5F5F5; $csc-title-color: #000; $csc-text-color: #1B1D27; diff --git a/sae-csc/src/app/pages/main/main.html b/sae-csc/src/app/pages/main/main.html index 90e48c5..94fdaf7 100644 --- a/sae-csc/src/app/pages/main/main.html +++ b/sae-csc/src/app/pages/main/main.html @@ -43,13 +43,14 @@ [disabled]="!appState.fromText.length"> + diff --git a/sae-csc/src/app/pages/main/main.ts b/sae-csc/src/app/pages/main/main.ts index e0fe7e9..249d805 100644 --- a/sae-csc/src/app/pages/main/main.ts +++ b/sae-csc/src/app/pages/main/main.ts @@ -23,7 +23,7 @@ import {StateInterface} from '../../redux/reducers'; export class Main { public appState: any = {}; - public displayBotWarning: boolean = true; + public displayBotWarning: boolean = false; constructor(private store: Store) { this.store.select(state => state.app).subscribe(app => { @@ -44,6 +44,7 @@ export class Main { displayWarningToCheckFilters() { this.displayBotWarning = true; + console.log('displayWarningToCheckFilters'); // update app, displayBotT // this.store.dispatch() } diff --git a/sae-csc/src/app/pages/similar-cases/similar-cases.html b/sae-csc/src/app/pages/similar-cases/similar-cases.html index 78a2215..fc91dce 100644 --- a/sae-csc/src/app/pages/similar-cases/similar-cases.html +++ b/sae-csc/src/app/pages/similar-cases/similar-cases.html @@ -43,9 +43,9 @@ } - - - +
+ +
@@ -86,17 +86,20 @@
- -
- {{ appState.similarCases.length }} cases found, 3 cases suggested -
+ +
+ {{ appState.similarCases.length }} cases found, 3 cases suggested +
+ } @if (displayedTab == 'similar-cases') {
diff --git a/sae-csc/src/app/pages/similar-cases/similar-cases.ts b/sae-csc/src/app/pages/similar-cases/similar-cases.ts index 8782812..db6efdb 100644 --- a/sae-csc/src/app/pages/similar-cases/similar-cases.ts +++ b/sae-csc/src/app/pages/similar-cases/similar-cases.ts @@ -6,6 +6,7 @@ import {StateInterface} from '../../redux/reducers'; import {Store} from '@ngrx/store'; import {NgClass} from '@angular/common'; import {RouterLink} from '@angular/router'; +import {FiltersGroup} from 'sae-lib/filters/filters-group/filters-group'; @Component({ selector: 'app-similar-cases', @@ -15,6 +16,7 @@ import {RouterLink} from '@angular/router'; BottomNavigation, NgClass, RouterLink, + FiltersGroup, ], templateUrl: './similar-cases.html', diff --git a/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.html b/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.html index c2f42e2..d1547f6 100644 --- a/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.html +++ b/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.html @@ -1,15 +1,19 @@
- + +
diff --git a/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.scss b/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.scss index 34e73b8..d081a81 100644 --- a/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.scss +++ b/sae-csc/src/app/shared/navigation/bottom-navigation/bottom-navigation.scss @@ -1,7 +1,8 @@ .bottom-navigation { - position: absolute; - top: 1000px; - padding: 0 60px 16px; + position: relative; + top: 280px; + padding: 0 0 16px; + a { text-decoration: none; diff --git a/sae-csc/src/app/shared/translate-texts/translate-texts.html b/sae-csc/src/app/shared/translate-texts/translate-texts.html index 10cdd7c..9d247c1 100644 --- a/sae-csc/src/app/shared/translate-texts/translate-texts.html +++ b/sae-csc/src/app/shared/translate-texts/translate-texts.html @@ -1,16 +1,18 @@ -
+
@if (!fileIsUploaded) { + - + + { // in demo mode, load demo filters - console.log('demo mode') + console.log('demo mode, on émet updateFilters') const newFilters = [ ['filter demo 1', 'filter demo 2'], @@ -66,10 +67,13 @@ export class TranslateTexts { ['filter demo 4', 'filter demo ABCD'], ['filter demo 5'], ] - this.updateFilters.emit(newFilters); + // this.updateFilters.emit(newFilters); + this.updateFilters.emit(); this.loadingResume = false; - }, this.debounceDuration); + }, this.debounceEnabled ? this.debounceDuration : 0); } + + } onFromTextChanged(e?: any): void { @@ -92,7 +96,16 @@ export class TranslateTexts { console.log('demo mode') this.toText = "Résumé de démo à titre d'exemple" this.loadingResume = false; - + + this.store.dispatch({ + type: ActionTypes.UPDATE_APP, + state: { + displayBot: true + } + }) + + // Emit updateFilters event to trigger onSelectedChoicesChange + this.updateFilters.emit(); }, this.debounceDuration); diff --git a/sae-csc/src/styles/app/styles/pages/_main.scss b/sae-csc/src/styles/app/styles/pages/_main.scss index b44095e..e3f08e1 100644 --- a/sae-csc/src/styles/app/styles/pages/_main.scss +++ b/sae-csc/src/styles/app/styles/pages/_main.scss @@ -32,7 +32,7 @@ body { } i { - font-size: 16px; + font-size: 20px; } }