Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: Modale d'enregistrement des données entreprises (avec CTA) #1243

Merged
Merged
Show file tree
Hide file tree
Changes from 54 commits
Commits
Show all changes
85 commits
Select commit Hold shift + click to select a range
833ea9f
cta wip
oumeimaelisbihani Oct 10, 2024
dc4a9b6
cta wip badge
oumeimaelisbihani Oct 10, 2024
0fa860d
remove topbar + true badge
oumeimaelisbihani Oct 14, 2024
334390b
header change
oumeimaelisbihani Oct 15, 2024
598aaf0
fix lint
oumeimaelisbihani Oct 15, 2024
5227a6c
change from review
oumeimaelisbihani Oct 15, 2024
3a8a2ed
add modal
oumeimaelisbihani Oct 15, 2024
759d189
add searchbar to modal
oumeimaelisbihani Oct 15, 2024
66d9e44
register siret + wip second step
oumeimaelisbihani Oct 16, 2024
eb57e9e
detail element in modal
oumeimaelisbihani Oct 16, 2024
40bbf62
select size + rename
oumeimaelisbihani Oct 17, 2024
6ecb801
refactor review changes
oumeimaelisbihani Oct 21, 2024
ea62cb2
synchro states between both CTA
oumeimaelisbihani Oct 21, 2024
94b3fe5
siret return
oumeimaelisbihani Oct 21, 2024
6b29e92
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Oct 21, 2024
1a797c7
typographie font-weight + size and siret update+beginning of manual r…
oumeimaelisbihani Oct 22, 2024
e92baa9
Merge branch 'feat/cta-vous-etes' into feat/modal-compagny-data
oumeimaelisbihani Oct 22, 2024
7f408cc
manual register
oumeimaelisbihani Oct 22, 2024
8d91ece
register mobile
oumeimaelisbihani Oct 22, 2024
fd11410
register update infos
oumeimaelisbihani Oct 23, 2024
5e589c8
rename files
oumeimaelisbihani Oct 23, 2024
bd8ee15
fix lint
oumeimaelisbihani Oct 23, 2024
e8c2925
with company utils
oumeimaelisbihani Oct 23, 2024
53c8fe7
fix type
oumeimaelisbihani Oct 23, 2024
a035b62
revet sitemap
oumeimaelisbihani Oct 23, 2024
373fc90
data on refresh
oumeimaelisbihani Oct 23, 2024
3edab65
changes from review
oumeimaelisbihani Oct 24, 2024
abb92e4
fixes
oumeimaelisbihani Oct 24, 2024
638e52a
ajout du debounce
oumeimaelisbihani Oct 24, 2024
321df59
change color tag
oumeimaelisbihani Oct 24, 2024
43cda90
responsive
oumeimaelisbihani Oct 24, 2024
21a6042
fix size change
oumeimaelisbihani Oct 24, 2024
b018d0a
review changes
oumeimaelisbihani Oct 28, 2024
35310fa
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Oct 28, 2024
ed46418
fix ci
oumeimaelisbihani Oct 28, 2024
87f94bb
review changes
oumeimaelisbihani Oct 29, 2024
60d21c7
background-size 100%
oumeimaelisbihani Oct 29, 2024
e7fce4c
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Oct 29, 2024
fb1f2ec
fix merge button
oumeimaelisbihani Oct 29, 2024
21473ab
fix type ci
oumeimaelisbihani Oct 29, 2024
c609e17
fix template button
oumeimaelisbihani Oct 30, 2024
59d1aa1
add close button + remove bold
oumeimaelisbihani Oct 30, 2024
ff53e5d
fix decalage avec header
oumeimaelisbihani Oct 30, 2024
0570c76
provide/inject openModal (à utiliser pour les autres accès à la modale)
oumeimaelisbihani Oct 30, 2024
dbbb1db
register close on header
oumeimaelisbihani Oct 30, 2024
39adb28
fix
oumeimaelisbihani Oct 30, 2024
73e936f
fix close
oumeimaelisbihani Oct 30, 2024
f698223
fixes
oumeimaelisbihani Oct 31, 2024
d1952d9
fix sass
oumeimaelisbihani Oct 31, 2024
9f7ddc5
first wave of fixes
oumeimaelisbihani Oct 31, 2024
5a34bee
fix scss
oumeimaelisbihani Oct 31, 2024
4287101
reviews
oumeimaelisbihani Oct 31, 2024
8b495f6
number of results as parameter
oumeimaelisbihani Oct 31, 2024
3c86f0a
fix close button align
oumeimaelisbihani Oct 31, 2024
1ea4b5d
align button
oumeimaelisbihani Oct 31, 2024
e7d8dbd
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Oct 31, 2024
60070d5
plug highlight in project
oumeimaelisbihani Oct 31, 2024
dac4a0e
spinner search siret
oumeimaelisbihani Nov 4, 2024
238a5b8
close on button click
oumeimaelisbihani Nov 4, 2024
07afa86
fix height
oumeimaelisbihani Nov 4, 2024
a04b064
style fix
oumeimaelisbihani Nov 4, 2024
c918526
input small placeholder text
oumeimaelisbihani Nov 5, 2024
ce7b9d9
lint fix
oumeimaelisbihani Nov 5, 2024
431ec41
resize loader
oumeimaelisbihani Nov 5, 2024
9cc8d21
fix: change image for modal. remove watch. resultcount by query param
yvalentin Nov 5, 2024
c4fb1c9
Merge remote-tracking branch 'origin/main' into feat/modal-compagny-data
oumeimaelisbihani Nov 6, 2024
17f0454
fix style
oumeimaelisbihani Nov 6, 2024
8808efb
review modifications
oumeimaelisbihani Nov 6, 2024
1bbef6e
Merge remote-tracking branch 'origin/feat/modal-compagny-data-review'…
oumeimaelisbihani Nov 6, 2024
b2923e6
automatic selection EI
oumeimaelisbihani Nov 6, 2024
8cd82d1
replace inject with store use
oumeimaelisbihani Nov 6, 2024
7f7d509
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Nov 6, 2024
594a387
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Nov 6, 2024
8add58a
fix lint sass
oumeimaelisbihani Nov 6, 2024
11ddbef
fixlint order
oumeimaelisbihani Nov 6, 2024
ff01353
input white
oumeimaelisbihani Nov 6, 2024
709b7da
Merge remote-tracking branch 'origin/main' into feat/modal-compagny-data
oumeimaelisbihani Nov 6, 2024
541d741
fix typo
oumeimaelisbihani Nov 6, 2024
e431bfc
add hover effect + access result siret
oumeimaelisbihani Nov 14, 2024
302f80d
hover effect
oumeimaelisbihani Nov 14, 2024
a6c329a
cursor
oumeimaelisbihani Nov 14, 2024
53056d7
Merge remote-tracking branch 'origin/main' into feat/modal-compagny-data
oumeimaelisbihani Nov 14, 2024
3e41244
Merge remote-tracking branch 'origin/release/siret-cross-recording' i…
oumeimaelisbihani Nov 14, 2024
43c951b
fix siret search + hover button
oumeimaelisbihani Nov 14, 2024
04dc740
fix error message
oumeimaelisbihani Nov 15, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ export class SireneController extends Controller {
/**
* Retrieve establishments informations used in front end
* for a single establishment using the SIRENE API if search by SIRET
* or for up to 3 establishments using the Recherche-entreprise API otherwise.
* or for up to 9 establishments using the Recherche-entreprise API otherwise.
* Also return the number of matches found
*
* @summary Search for establishments from a query
Expand All @@ -47,14 +47,15 @@ export class SireneController extends Controller {
*/

@Example<Establishment>(exampleEstablishment)
@Get('{query}')
@Get('{query}/{resultCount}')
public async getEstablishmentBySiret(
@Path() query: string,
@Path() resultCount: number,
@Res() requestFailedResponse: TsoaResponse<500, ErrorJSON>,
@Res() _validationFailedResponse: TsoaResponse<422, ValidateErrorJSON>,
@Res() notFoundResponse: TsoaResponse<404, EstablishmentNotFoundErrorJSON>
): Promise<EstablishmentSearch> {
const establishmentResult = await new EstablishmentService().search(query)
const establishmentResult = await new EstablishmentService().search(query, resultCount)

if (establishmentResult.isErr) {
const err = establishmentResult.error
Expand Down
6 changes: 0 additions & 6 deletions apps/web/public/css/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -186,12 +186,6 @@ button.fr-link:hover, .tee-router-link:hover {
line-height: 1.2em;
}

/* TRACK INPUT */
.tee-resp-info-block {
text-indent: -3.5rem;
padding-left: 3.5rem;
}

/* CUSTOM BUTTON INPUT */
.tee-btn-next {
justify-content: end;
Expand Down
31 changes: 31 additions & 0 deletions apps/web/public/images/TEE-modal-bottom-mobile.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
115 changes: 115 additions & 0 deletions apps/web/public/images/TEE-modal-bottom.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
11 changes: 10 additions & 1 deletion apps/web/src/WebApp.vue
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
<TeeDsfrPersonalizeConsent />
<div>
<TeeHeader />
<TeeRegisterModal v-if="registerModal" />
<TeeMatomo />
<router-view v-if="isReady" />
<template v-else>
Expand Down Expand Up @@ -32,18 +33,26 @@ import { useNavigationStore } from './stores/navigation'
import TeeFooter from './components/TeeFooter.vue'
import Translation from './utils/translation'
import Cookie from './utils/cookies'
import CompanyDataStorage from './utils/storage/companyDataStorage'

const navigationStore = useNavigationStore()
const router = useRouter()
const route = useRoute()

const registerModal = ref<boolean>(false)
const isReady = computed<boolean>(() => {
return navigationStore.isReady
})

const toggleRegisterModal = (forceStatus: boolean | undefined) => {
oumeimaelisbihani marked this conversation as resolved.
Show resolved Hide resolved
registerModal.value = forceStatus || !registerModal.value
document.body.style.overflow = registerModal.value ? 'hidden' : ''
}
provide('toggleRegisterModal', toggleRegisterModal)

onBeforeMount(() => {
Translation.setLocale('fr')
Cookie.setCookies()
CompanyDataStorage.updateData()
})

onMounted(async () => {
Expand Down
6 changes: 0 additions & 6 deletions apps/web/src/assets/custom.css
Original file line number Diff line number Diff line change
Expand Up @@ -183,12 +183,6 @@ button.fr-link:hover, .tee-router-link:hover {
line-height: 1.2em;
}

/* TRACK INPUT */
.tee-resp-info-block {
text-indent: -3.5rem;
padding-left: 3.5rem;
}

/* CUSTOM BUTTON INPUT */
.tee-btn-next {
justify-content: end;
Expand Down
4 changes: 3 additions & 1 deletion apps/web/src/assets/main.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
@import "scss/card";
@import "scss/checkbox";
@import "scss/display";
@import 'scss/footer';
@import "scss/gradient";
@import "scss/grid";
@import "scss/header";
Expand All @@ -15,8 +16,9 @@
@import "scss/radius";
@import "scss/router";
@import "scss/searchBar";
@import "scss/select";
@import "scss/sidemenu";
@import "scss/tab";
@import "scss/tag";
@import "scss/transition";
@import "scss/typography";
@import 'scss/footer';
25 changes: 25 additions & 0 deletions apps/web/src/assets/scss/searchBar.scss
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
@use "setting";
@use 'sass:meta';
@use 'sass:map';

input[type="search"] {
&::-webkit-search-decoration,
&::-webkit-search-cancel-button,
Expand All @@ -21,3 +25,24 @@ input[type="search"] {
color: var(--text-disabled-grey);
}
}

.fr-search-bar {
&-lg {
.fr-input, .search-button {
max-height: 3rem;
line-height: 3rem;
}
}

@each $color, $properties in setting.$colors {
&--#{$color} {
.fr-input, .search-button {
@if meta.type-of($properties) == map {
box-shadow: inset 0 -2px 0 0 map.get($properties, "color");
} @else {
box-shadow: inset 0 -2px 0 0 $properties;
}
}
}
}
}
5 changes: 5 additions & 0 deletions apps/web/src/assets/scss/select.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
@use 'setting';

.fr-select {
oumeimaelisbihani marked this conversation as resolved.
Show resolved Hide resolved
background-color: setting.$white;
}
6 changes: 5 additions & 1 deletion apps/web/src/assets/scss/setting/_typography.scss
Original file line number Diff line number Diff line change
Expand Up @@ -8,4 +8,8 @@ $line-heights: (
$font-styles: (
italic,
normal,
)
);

$text-decorations: (
underline
);
9 changes: 9 additions & 0 deletions apps/web/src/assets/scss/transition.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.fade-enter-active,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

question/suggestion: j'imagine que ce style a été défini pour la Transition que tu utilises dans le TeeRegisterCTA. C'est volontaire de le déclarer globalement ici plutôt que sur le style scoped du composant (ce qui appliquerait ce style uniquement à la transition du composant plutôt qu'à toutes les transitions de type fade sur l'app)? si non, je le mettrais plutôt dans le style scope du composant

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes c'était volontaire je me dis qu'avec l'utilisation du composant Transition c'est plus simple de centraliser les différentes transitions possibles (déjà dans le cas de la transition fade ça va être utilisé aussi par le otherProject)

.fade-leave-active {
transition: opacity 0.5s ease;
}

.fade-enter-from,
.fade-leave-to {
opacity: 0;
}
6 changes: 6 additions & 0 deletions apps/web/src/assets/scss/typography.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,12 @@
@include tool.line-height($size)
}
}

@each $decoration in setting.$text-decorations {
&--#{$decoration} {
text-decoration: $decoration;
}
}
}

.tee-font {
Expand Down
4 changes: 0 additions & 4 deletions apps/web/src/auto-imports.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,6 @@ declare global {
const onServerPrefetch: typeof import('vue')['onServerPrefetch']
const onUnmounted: typeof import('vue')['onUnmounted']
const onUpdated: typeof import('vue')['onUpdated']
const onWatcherCleanup: typeof import('vue')['onWatcherCleanup']
const provide: typeof import('vue')['provide']
const reactive: typeof import('vue')['reactive']
const readonly: typeof import('vue')['readonly']
Expand All @@ -61,9 +60,7 @@ declare global {
const useCssVars: typeof import('vue')['useCssVars']
const useHead: typeof import('@unhead/vue')['useHead']
const useHeadSafe: typeof import('@unhead/vue')['useHeadSafe']
const useId: typeof import('vue')['useId']
const useLink: typeof import('vue-router')['useLink']
const useModel: typeof import('vue')['useModel']
const useRoute: typeof import('vue-router')['useRoute']
const useRouter: typeof import('vue-router')['useRouter']
const useScheme: typeof import('@gouvminint/vue-dsfr')['useScheme']
Expand All @@ -73,7 +70,6 @@ declare global {
const useServerSeoMeta: typeof import('@unhead/vue')['useServerSeoMeta']
const useSlots: typeof import('vue')['useSlots']
const useTabs: typeof import('@gouvminint/vue-dsfr')['useTabs']
const useTemplateRef: typeof import('vue')['useTemplateRef']
const watch: typeof import('vue')['watch']
const watchEffect: typeof import('vue')['watchEffect']
const watchPostEffect: typeof import('vue')['watchPostEffect']
Expand Down
10 changes: 10 additions & 0 deletions apps/web/src/components.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -100,9 +100,19 @@ declare module 'vue' {
TeeListNoResults: typeof import('./components/element/TeeListNoResults.vue')['default']
TeeMatomo: typeof import('./components/TeeMatomo.vue')['default']
TeeNoResult: typeof import('./components/element/TeeNoResult.vue')['default']
TeeProfileActivity: typeof import('./components/identification/details/TeeProfileActivity.vue')['default']
TeeProfileDetails: typeof import('./components/identification/details/TeeProfileDetails.vue')['default']
TeeProfileElement: typeof import('./components/identification/details/TeeProfileElement.vue')['default']
TeeProfileLocalisation: typeof import('./components/identification/details/TeeProfileLocalisation.vue')['default']
TeeProfileSiret: typeof import('./components/identification/details/TeeProfileSiret.vue')['default']
TeeProfileSize: typeof import('./components/identification/details/TeeProfileSize.vue')['default']
TeeProjectButton: typeof import('./components/project/TeeProjectButton.vue')['default']
TeeQuestionnaire: typeof import('./components/questionnaire/TeeQuestionnaire.vue')['default']
TeeQuestionnaireResult: typeof import('./components/questionnaire/TeeQuestionnaireResult.vue')['default']
TeeRegisterCTA: typeof import('./components/identification/TeeRegisterCTA.vue')['default']
TeeRegisterModal: typeof import('./components/identification/TeeRegisterModal.vue')['default']
TeeRegisterSiret: typeof import('./components/identification/TeeRegisterSiret.vue')['default']
TeeRegisterSiretBar: typeof import('./components/identification/TeeRegisterSiretBar.vue')['default']
TeeSpinner: typeof import('./components/element/TeeSpinner.vue')['default']
TeeTabs: typeof import('./components/element/TeeTabs.vue')['default']
ThemeCard: typeof import('./components/theme/select/ThemeCard.vue')['default']
Expand Down
16 changes: 4 additions & 12 deletions apps/web/src/components/header/TeeDsfrHeader.vue
Original file line number Diff line number Diff line change
Expand Up @@ -43,10 +43,7 @@
@click.prevent.stop="showSearchModal()"
/>
<div class="fr-hidden-lg">
<RegisterCTA
:registration-status="registrationStatus"
@click="updateStatus"
/>
<TeeRegisterCTA />
</div>
<button
v-if="isWithSlotNav || quickLinks?.length"
Expand Down Expand Up @@ -115,10 +112,7 @@
</template>
</div>
<div class="fr-my-auto fr-px-4v fr-hidden fr-unhidden-lg">
<RegisterCTA
:registration-status="registrationStatus"
@click="updateStatus"
/>
<TeeRegisterCTA />
</div>
<div
v-if="showSearch"
Expand Down Expand Up @@ -239,14 +233,12 @@ const props = withDefaults(defineProps<DsfrHeaderProps>(), {
closeMenuModalLabel: 'Fermer',
homeLabel: 'Accueil'
})
const registrationStatus = ref<boolean>(false)
const updateStatus = () => {
registrationStatus.value = !registrationStatus.value
}

const emit = defineEmits<{
(e: 'update:modelValue', payload: string): void
(e: 'search', payload: string): void
(e: 'language-select', payload: DsfrLanguageSelectorElement): void
(e: 'openRegister'): void
}>()

const languageSelector = toRef(props, 'languageSelector')
Expand Down
82 changes: 0 additions & 82 deletions apps/web/src/components/identification/RegisterCTA.vue

This file was deleted.

Loading
Loading