project-booster-vue 9.49.1 → 9.51.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/pedagogy/PbPedagogy.vue +19 -19
- package/src/components/question/PbQuestion-Features-With-Progress-Bar.stories.mdx +138 -0
- package/src/components/question/PbQuestion.vue +52 -9
- package/src/components/question/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-rework-questions-step-with-progress-bar-image-card-width-progress-bar-1-snap.png +0 -0
- package/src/components/question/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-rework-questions-step-with-progress-bar-text-card-width-progress-bar-1-snap.png +0 -0
- package/src/components/question/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-step-with-progress-bar-image-card-width-progress-bar-1-snap.png +0 -0
- package/src/components/question/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-step-with-progress-bar-text-card-width-progress-bar-1-snap.png +0 -0
- package/src/components/rework/cards/3-cards-list.json +34 -0
- package/src/components/rework/cards/4-cards-list.json +44 -0
- package/src/components/rework/cards/MPbCards.stories.mdx +1493 -0
- package/src/components/rework/cards/MPbCards.vue +547 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-align-horizontal-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-align-text-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-align-vertical-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-blank-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-button-href-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-button-label-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-card-link-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-degradations-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-disabled-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-flag-label-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-flag-theme-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-flattened-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-hero-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-image-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-image-is-contained-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-image-ratio-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-image-title-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-link-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-min-card-ratio-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-selectable-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-selected-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-text-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-title-1-snap.png +0 -0
- package/src/components/rework/cards/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-cards-m-pb-card-/360/237/247/254-features-type-icon-1-snap.png +0 -0
- package/src/components/rework/cards/cards-list.json +24 -0
- package/src/components/rework/cards/decorators/MPbCardSelectionIndicator.vue +95 -0
- package/src/components/rework/cards/decorators/MPbCardTypeIndicator.vue +66 -0
- package/src/components/rework/products/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-products-m-pb-products-/360/237/246/240-101-sandbox-1-snap.png +0 -0
- package/src/components/rework/question/MPbQuestion.stories.mdx +85 -0
- package/src/components/rework/question/MPbQuestion.vue +1368 -0
- package/src/components/rework/question/city-search/MPbCitySearch.stories.mdx +189 -0
- package/src/components/rework/question/city-search/MPbCitySearch.vue +633 -0
- package/src/components/rework/question/city-search/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-m-pb-city-search-/360/237/246/240-101-sandbox-1-snap.png +0 -0
- package/src/components/rework/question/city-search/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-m-pb-city-search-/360/237/246/240-showcase-feature-customize-1-snap.png +0 -0
- package/src/components/rework/question/city-search/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-m-pb-city-search-/360/237/246/240-showcase-feature-previous-value-from-answer-1-snap.png +0 -0
- package/src/components/rework/question/city-search/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-m-pb-city-search-/360/237/246/240-showcase-feature-previous-value-from-default-1-snap.png +0 -0
- package/src/components/rework/question/city-search/default-payload.json +9 -0
- package/src/components/rework/question/city-search/google-maps-api.ts +30 -0
- package/src/components/rework/question/default-payload.json +56 -0
- package/src/components/rework/question/incremental-amount-input/IncrementalAmount.ts +26 -0
- package/src/components/rework/question/incremental-amount-input/MPbIncrementalAmountInput.stories.mdx +50 -0
- package/src/components/rework/question/incremental-amount-input/MPbIncrementalAmountInput.vue +366 -0
- package/src/components/rework/question/incremental-amount-input/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-rework-questions-m-pb-incremental-amount-input-/360/237/246/240-101-sandbox-1-snap.png +0 -0
- package/src/components/rework/question/incremental-amount-input/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-scenario-questions-pb-incremental-amount-input-/360/237/246/240-101-sandbox-1-snap.png +0 -0
- package/src/components/rework/question/incremental-amount-input/default-payload.json +12 -0
- package/src/components/rework/question/sortAnswers.ts +56 -0
- package/src/components/rework/restitution/MPbRestitutionList.stories.mdx +150 -0
- package/src/components/rework/restitution/MPbRestitutionList.vue +533 -0
- package/src/components/rework/restitution/MPbRestitutionListBlock.vue +228 -0
- package/src/components/rework/restitution/MPbRestitutionListLine.vue +170 -0
- package/src/components/rework/restitution/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-restitution-pb-restitution-/360/237/246/240-feature-call-to-action-with-modal-1-snap.png +0 -0
- package/src/components/rework/restitution/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-restitution-pb-restitution-/360/237/246/240-feature-conditional-exit-options-1-snap.png +0 -0
- package/src/components/rework/restitution/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-restitution-pb-restitution-/360/237/246/240-features-with-a-popin-save-action-1-snap.png +0 -0
- package/src/components/rework/restitution/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-restitution-pb-restitution-/360/237/246/240-features-with-exit-options-1-snap.png +0 -0
- package/src/components/rework/restitution/__snapshots__/storyshots-puppeteer-test-puppeteer-ts-image-storyshots-project-booster-components-restitution-pb-restitution-/360/237/246/240-features-without-price-bar-1-snap.png +0 -0
- package/src/components/rework/restitution/restitution-list-default.json +47 -0
- package/src/components/rework/styles/global.scss +4 -0
- package/src/components/rework/ui/progress/MPbProgress.vue +142 -0
- package/src/components/rework/ui/progress/PbProgress.stories.mdx +38 -0
- package/src/components/rework/ui/progress/default-payload.json +6 -0
- package/src/components/scenario/PbScenario-Estimator-Boiler-Pellet.stories.mdx +245 -0
- package/src/components/scenario/PbScenario-Estimator-Floor-Insulation.stories.mdx +245 -0
- package/src/components/scenario/PbScenario.vue +48 -13
- package/src/components/scenario/scenarii/estimator-hpwa.json +2478 -0
- package/src/components/scenario/scenarii/floor-insulation.json +2416 -0
- package/src/components/scenario/scenarii/pellet-boiler.json +2474 -0
- package/src/components/trezor/PbTrezor.vue +7 -3
- package/src/services/api/trezorApi.ts +4 -7
- package/src/stores/modules/trezorStore.ts +12 -1
- package/src/types/pb/Scenario.ts +12 -0
package/package.json
CHANGED
|
@@ -21,20 +21,22 @@
|
|
|
21
21
|
>
|
|
22
22
|
{{ payload.viewModel.instructionsButton.text }}
|
|
23
23
|
</m-flex>
|
|
24
|
-
<m-button
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
24
|
+
<m-flex class="pb-pedagogy__content--button" direction="column">
|
|
25
|
+
<m-button
|
|
26
|
+
v-if="payload.viewModel.downloadButton"
|
|
27
|
+
:theme="payload.viewModel.downloadButton.theme"
|
|
28
|
+
:label="payload.viewModel.downloadButton.label"
|
|
29
|
+
class="pb-pedagogy__content-upload-button mc-button--full"
|
|
30
|
+
@click="handleButtonLinkClicked"
|
|
31
|
+
/>
|
|
32
|
+
<m-button
|
|
33
|
+
v-for="action in payload.callToActions"
|
|
34
|
+
:theme="action.bordered ? 'bordered' : 'solid'"
|
|
35
|
+
:label="action.label"
|
|
36
|
+
class="pb-pedagogy__content-action-button mc-button--full"
|
|
37
|
+
@click="handleValidateClicked(action)"
|
|
38
|
+
/>
|
|
39
|
+
</m-flex>
|
|
38
40
|
<m-flex
|
|
39
41
|
justify-content="center"
|
|
40
42
|
align-items="center"
|
|
@@ -141,12 +143,10 @@ export default defineComponent({
|
|
|
141
143
|
window.open(targetUrl, '_blank');
|
|
142
144
|
},
|
|
143
145
|
|
|
144
|
-
async handleValidateClicked() {
|
|
146
|
+
async handleValidateClicked(action: any) {
|
|
145
147
|
this.$emit('step-completed', {
|
|
146
|
-
answers:
|
|
147
|
-
|
|
148
|
-
: null,
|
|
149
|
-
nextStep: this.payload.multiSelect.actions.VALIDATE.nextStep,
|
|
148
|
+
answers: action.isAnswer ? [action] : null,
|
|
149
|
+
nextStep: action.nextStep,
|
|
150
150
|
});
|
|
151
151
|
},
|
|
152
152
|
},
|
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
import { nestedAppDecorator } from '../../../.storybook/nested-app-decorator';
|
|
2
|
+
import { Story, Preview, Meta, Props, ArgsTable, Source, Canvas } from '@storybook/addon-docs';
|
|
3
|
+
import PbQuestion from './PbQuestion';
|
|
4
|
+
import { TemplateSandbox } from './PbQuestion.stories.mdx';
|
|
5
|
+
|
|
6
|
+
<Meta
|
|
7
|
+
title="Project Booster/Rework/Questions/Step With ProgressBar"
|
|
8
|
+
component={PbQuestion}
|
|
9
|
+
argTypes={{
|
|
10
|
+
onStepCompleted: {
|
|
11
|
+
action: 'Step completed',
|
|
12
|
+
table: { disable: true },
|
|
13
|
+
},
|
|
14
|
+
}}
|
|
15
|
+
decorators={[
|
|
16
|
+
nestedAppDecorator(
|
|
17
|
+
{
|
|
18
|
+
actions: {
|
|
19
|
+
sendEventToBus({}, payload) {
|
|
20
|
+
console.log('Event sent to bus', payload);
|
|
21
|
+
},
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
[],
|
|
25
|
+
),
|
|
26
|
+
]}
|
|
27
|
+
parameters={{
|
|
28
|
+
layout: 'fullscreen',
|
|
29
|
+
}}
|
|
30
|
+
/>
|
|
31
|
+
|
|
32
|
+
# `PbQuestion` - Image card width progress bar
|
|
33
|
+
|
|
34
|
+
##
|
|
35
|
+
|
|
36
|
+
It is possible to force the cards' layout on mobile from **2 cards per line** to **1 card per line**. To achieve this, use the
|
|
37
|
+
`forceOneCardPerLineOnMobile` property on the question `viewModel`:
|
|
38
|
+
|
|
39
|
+
export const forceOnCardPerLineOnMobilePayload = {
|
|
40
|
+
viewModel: {
|
|
41
|
+
answersComponent: 'MPbCard',
|
|
42
|
+
widthFromL: true,
|
|
43
|
+
progressBar: true,
|
|
44
|
+
label: 'Vous êtes :',
|
|
45
|
+
modalView: {
|
|
46
|
+
link: {
|
|
47
|
+
textContent: 'Où trouver mon revenu fiscal de référence ?',
|
|
48
|
+
hrefContent: 'https://google.fr/',
|
|
49
|
+
},
|
|
50
|
+
},
|
|
51
|
+
showNotification: false,
|
|
52
|
+
},
|
|
53
|
+
answers: {
|
|
54
|
+
'ANSWER-1': {
|
|
55
|
+
code: 'ANSWER-1',
|
|
56
|
+
viewModel: {
|
|
57
|
+
title: 'Maison',
|
|
58
|
+
image: 'https://storage.googleapis.com/project-booster-media/energyrenovation/house.png',
|
|
59
|
+
cardMinRatio: 'auto',
|
|
60
|
+
},
|
|
61
|
+
},
|
|
62
|
+
'ANSWER-2': {
|
|
63
|
+
code: 'ANSWER-2',
|
|
64
|
+
viewModel: {
|
|
65
|
+
title: 'Appartement',
|
|
66
|
+
image: 'https://storage.googleapis.com/project-booster-media/energyrenovation/apartement.jpg',
|
|
67
|
+
cardMinRatio: 'auto',
|
|
68
|
+
},
|
|
69
|
+
warningMessage: {
|
|
70
|
+
type: 'info',
|
|
71
|
+
htmlContent: '<p>Mon message</p>',
|
|
72
|
+
link: {
|
|
73
|
+
textContent: '',
|
|
74
|
+
hrefContent: '',
|
|
75
|
+
},
|
|
76
|
+
},
|
|
77
|
+
},
|
|
78
|
+
},
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
<Source language="json" code={JSON.stringify(forceOnCardPerLineOnMobilePayload, null, ' ')} />
|
|
82
|
+
|
|
83
|
+
<Canvas>
|
|
84
|
+
<Story
|
|
85
|
+
name="Image card width progress bar"
|
|
86
|
+
inline={false}
|
|
87
|
+
height="862px"
|
|
88
|
+
parameters={{ controls: { disable: true } }}
|
|
89
|
+
args={{ payload: forceOnCardPerLineOnMobilePayload, minHeight: 'auto' }}
|
|
90
|
+
>
|
|
91
|
+
{TemplateSandbox.bind({})}
|
|
92
|
+
</Story>
|
|
93
|
+
</Canvas>
|
|
94
|
+
|
|
95
|
+
# `PbQuestion` - Text card width progress bar
|
|
96
|
+
|
|
97
|
+
##
|
|
98
|
+
|
|
99
|
+
It is possible to force the cards' layout on mobile from **2 cards per line** to **1 card per line**. To achieve this, use the
|
|
100
|
+
`TextCardPayload` property on the question `viewModel`:
|
|
101
|
+
|
|
102
|
+
export const TextCardPayload = {
|
|
103
|
+
viewModel: {
|
|
104
|
+
answersComponent: 'MPbCard',
|
|
105
|
+
widthFromL: true,
|
|
106
|
+
progressBar: true,
|
|
107
|
+
label: 'Vous êtes :',
|
|
108
|
+
showNotification: true,
|
|
109
|
+
},
|
|
110
|
+
answers: {
|
|
111
|
+
'ANSWER-1': {
|
|
112
|
+
code: 'ANSWER-1',
|
|
113
|
+
viewModel: {
|
|
114
|
+
title: 'Propriétaire',
|
|
115
|
+
},
|
|
116
|
+
},
|
|
117
|
+
'ANSWER-2': {
|
|
118
|
+
code: 'ANSWER-2',
|
|
119
|
+
viewModel: {
|
|
120
|
+
title: 'Locataire',
|
|
121
|
+
},
|
|
122
|
+
},
|
|
123
|
+
},
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
<Source language="json" code={JSON.stringify(TextCardPayload, null, ' ')} />
|
|
127
|
+
|
|
128
|
+
<Canvas>
|
|
129
|
+
<Story
|
|
130
|
+
name="Text card width progress bar"
|
|
131
|
+
inline={false}
|
|
132
|
+
height="862px"
|
|
133
|
+
parameters={{ controls: { disable: true } }}
|
|
134
|
+
args={{ payload: TextCardPayload, minHeight: 'auto' }}
|
|
135
|
+
>
|
|
136
|
+
{TemplateSandbox.bind({})}
|
|
137
|
+
</Story>
|
|
138
|
+
</Canvas>
|
|
@@ -51,19 +51,13 @@
|
|
|
51
51
|
</div>
|
|
52
52
|
</div>
|
|
53
53
|
</div>
|
|
54
|
-
<m-container fluid class="pb-question__answers-container">
|
|
54
|
+
<m-container fluid class="pb-question__answers-container" :class="{ progress: progressBar }">
|
|
55
55
|
<m-flexy class="pb-question__answers-container-flexy">
|
|
56
|
-
<transition-group
|
|
57
|
-
:class="`pb-question__answers ${
|
|
58
|
-
displayedAnswers && displayedAnswers.length < 4 ? 'pb-question__answers--centered' : ''
|
|
59
|
-
}`"
|
|
60
|
-
:name="showMoreAnimation"
|
|
61
|
-
tag="div"
|
|
62
|
-
>
|
|
56
|
+
<transition-group :class="`pb-question__answers`" :name="showMoreAnimation" tag="div">
|
|
63
57
|
<m-flexy-col
|
|
64
58
|
v-for="answer in displayedAnswers"
|
|
65
59
|
:key="`pb-question__answers-${answer.code}`"
|
|
66
|
-
:width="payload.viewModel.forceOneCardPerLineOnMobile ? 'full' : '
|
|
60
|
+
:width="payload.viewModel.forceOneCardPerLineOnMobile ? 'full' : '1of3'"
|
|
67
61
|
:width-from-m="payload.viewModel.widthFromM ? payload.viewModel.widthFromM : '1of3'"
|
|
68
62
|
:width-from-l="payload.viewModel.widthFromL ? payload.viewModel.widthFromL : '1of4'"
|
|
69
63
|
>
|
|
@@ -171,6 +165,13 @@
|
|
|
171
165
|
{{ payload.viewModel.footer.label }}
|
|
172
166
|
</div>
|
|
173
167
|
</div>
|
|
168
|
+
<div class="pb-question__modal-link" v-if="payload.viewModel.link">
|
|
169
|
+
<m-link
|
|
170
|
+
:label="payload.viewModel.link.textContent"
|
|
171
|
+
:href="payload.viewModel.link.hrefContent"
|
|
172
|
+
@click.prevent="handleShowModal"
|
|
173
|
+
></m-link>
|
|
174
|
+
</div>
|
|
174
175
|
</div>
|
|
175
176
|
<pb-sticky-footer
|
|
176
177
|
v-show="
|
|
@@ -366,6 +367,7 @@ import MImage from '../mozaic/image/MImage.vue';
|
|
|
366
367
|
import MLink from '../mozaic/link/MLink.vue';
|
|
367
368
|
import PbCard from '../cards/PbCard.vue';
|
|
368
369
|
import PbStickyFooter from '../sticky-footer/PbStickyFooter.vue';
|
|
370
|
+
import PbCitySearch from './city-search/PbCitySearch.vue';
|
|
369
371
|
import { sortAnswers } from './sortAnswers';
|
|
370
372
|
import { areConditionsValid } from '../../services/scenarioConditionals';
|
|
371
373
|
import { decorate } from '@/services/decorate';
|
|
@@ -401,6 +403,7 @@ export default defineComponent({
|
|
|
401
403
|
MLink,
|
|
402
404
|
PbCard,
|
|
403
405
|
PbStickyFooter,
|
|
406
|
+
PbCitySearch,
|
|
404
407
|
},
|
|
405
408
|
|
|
406
409
|
props: {
|
|
@@ -478,6 +481,10 @@ export default defineComponent({
|
|
|
478
481
|
displayVideo: false,
|
|
479
482
|
pbQuestionActionsButtonsMaxHeight: 0,
|
|
480
483
|
decorate,
|
|
484
|
+
progressBar: false,
|
|
485
|
+
slotComponent: false,
|
|
486
|
+
showNotification: false,
|
|
487
|
+
showModal: false,
|
|
481
488
|
}),
|
|
482
489
|
|
|
483
490
|
computed: {
|
|
@@ -514,6 +521,7 @@ export default defineComponent({
|
|
|
514
521
|
this.selectedAnswers = new Map<string, boolean>();
|
|
515
522
|
this.updateSelectedAnswers();
|
|
516
523
|
this.updatePbQuestionActionsButtonsSizeHeight();
|
|
524
|
+
this.progressBar = this.payload.viewModel?.progressBar || false;
|
|
517
525
|
},
|
|
518
526
|
|
|
519
527
|
beforeUnmount() {
|
|
@@ -788,6 +796,9 @@ export default defineComponent({
|
|
|
788
796
|
},
|
|
789
797
|
});
|
|
790
798
|
},
|
|
799
|
+
handleShowModal() {
|
|
800
|
+
this.showModal = !this.showModal;
|
|
801
|
+
},
|
|
791
802
|
},
|
|
792
803
|
});
|
|
793
804
|
</script>
|
|
@@ -969,6 +980,22 @@ $answers-apparition-duration: '0.5s';
|
|
|
969
980
|
&-flexy {
|
|
970
981
|
width: 100%;
|
|
971
982
|
}
|
|
983
|
+
|
|
984
|
+
&.progress {
|
|
985
|
+
max-width: 591px;
|
|
986
|
+
}
|
|
987
|
+
|
|
988
|
+
&-progress {
|
|
989
|
+
max-width: calc(591px - 2rem);
|
|
990
|
+
width: 100%;
|
|
991
|
+
margin: 0 auto;
|
|
992
|
+
|
|
993
|
+
&-label {
|
|
994
|
+
margin: $mu200 0 0 0;
|
|
995
|
+
@include set-font-face('semi-bold');
|
|
996
|
+
@include set-font-scale('06', 'l');
|
|
997
|
+
}
|
|
998
|
+
}
|
|
972
999
|
}
|
|
973
1000
|
|
|
974
1001
|
&__answers {
|
|
@@ -1271,6 +1298,22 @@ $answers-apparition-duration: '0.5s';
|
|
|
1271
1298
|
@include set-font-face('regular');
|
|
1272
1299
|
}
|
|
1273
1300
|
}
|
|
1301
|
+
|
|
1302
|
+
&__notifications {
|
|
1303
|
+
width: calc(100% - 30px);
|
|
1304
|
+
margin: auto;
|
|
1305
|
+
}
|
|
1306
|
+
|
|
1307
|
+
&__redirect-link {
|
|
1308
|
+
width: calc(100% - 30px);
|
|
1309
|
+
margin: auto;
|
|
1310
|
+
margin-top: $mu200;
|
|
1311
|
+
}
|
|
1312
|
+
|
|
1313
|
+
&__modal-link {
|
|
1314
|
+
width: calc(591px - 2rem);
|
|
1315
|
+
margin: 1rem auto;
|
|
1316
|
+
}
|
|
1274
1317
|
}
|
|
1275
1318
|
</style>
|
|
1276
1319
|
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cards": {
|
|
3
|
+
"CARD-1": {
|
|
4
|
+
"code": "CARD-1",
|
|
5
|
+
"viewModel": {
|
|
6
|
+
"title": "Par Chat",
|
|
7
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/store.jpg",
|
|
8
|
+
"text": "Sit voluptatem accusantium",
|
|
9
|
+
"buttonLabel": "Contacter",
|
|
10
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"CARD-2": {
|
|
14
|
+
"code": "CARD-2",
|
|
15
|
+
"viewModel": {
|
|
16
|
+
"title": "Par téléphone",
|
|
17
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/appointment.jpg",
|
|
18
|
+
"text": "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium",
|
|
19
|
+
"buttonLabel": "Contacter",
|
|
20
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"CARD-3": {
|
|
24
|
+
"code": "CARD-3",
|
|
25
|
+
"viewModel": {
|
|
26
|
+
"title": "En autonomie",
|
|
27
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/photo-OAA-rangement-lien-tool.jpg",
|
|
28
|
+
"text": "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium",
|
|
29
|
+
"buttonLabel": "Contacter",
|
|
30
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
31
|
+
}
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
{
|
|
2
|
+
"cards": {
|
|
3
|
+
"CARD-1": {
|
|
4
|
+
"code": "CARD-1",
|
|
5
|
+
"viewModel": {
|
|
6
|
+
"title": "Par Chat",
|
|
7
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/store.jpg",
|
|
8
|
+
"text": "Sit voluptatem accusantium",
|
|
9
|
+
"buttonLabel": "Contacter",
|
|
10
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
11
|
+
}
|
|
12
|
+
},
|
|
13
|
+
"CARD-2": {
|
|
14
|
+
"code": "CARD-2",
|
|
15
|
+
"viewModel": {
|
|
16
|
+
"title": "Par téléphone",
|
|
17
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/appointment.jpg",
|
|
18
|
+
"text": "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium",
|
|
19
|
+
"buttonLabel": "Contacter",
|
|
20
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
"CARD-3": {
|
|
24
|
+
"code": "CARD-3",
|
|
25
|
+
"viewModel": {
|
|
26
|
+
"title": "En autonomie",
|
|
27
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/photo-OAA-rangement-lien-tool.jpg",
|
|
28
|
+
"text": "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium",
|
|
29
|
+
"buttonLabel": "Contacter",
|
|
30
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
31
|
+
}
|
|
32
|
+
},
|
|
33
|
+
"CARD-4": {
|
|
34
|
+
"code": "CARD-4",
|
|
35
|
+
"viewModel": {
|
|
36
|
+
"title": "En ??",
|
|
37
|
+
"image": "https://storage.googleapis.com/project-booster-media/common/services/installation.jpg",
|
|
38
|
+
"text": "Sed ut perspiciatis unde omnis iste natus error sit voluptatem accusantium",
|
|
39
|
+
"buttonLabel": "Contacter",
|
|
40
|
+
"buttonHref": "http://leroymerlin.fr"
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|