mautourco-components 0.2.13 → 0.2.15

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.
Files changed (35) hide show
  1. package/dist/components/atoms/Icon/icons/PlusCircleIcon.d.ts +12 -0
  2. package/dist/components/atoms/Icon/icons/PlusCircleIcon.js +36 -0
  3. package/dist/components/atoms/Icon/icons/QuotationIcon.d.ts +8 -0
  4. package/dist/components/atoms/Icon/icons/QuotationIcon.js +36 -0
  5. package/dist/components/atoms/Icon/icons/registry.d.ts +2 -0
  6. package/dist/components/atoms/Icon/icons/registry.js +4 -0
  7. package/dist/components/atoms/Inputs/DropdownInput/DropdownInput.js +15 -3
  8. package/dist/components/organisms/MultipleQuotationDocket/MultipleQuotationDocket.d.ts +64 -0
  9. package/dist/components/organisms/MultipleQuotationDocket/MultipleQuotationDocket.js +45 -0
  10. package/dist/components/organisms/MultipleQuotationDocket/index.d.ts +2 -0
  11. package/dist/components/organisms/MultipleQuotationDocket/index.js +1 -0
  12. package/dist/components/organisms/QuoteHeader/QuoteHeader.css +2142 -0
  13. package/dist/components/organisms/QuoteHeader/QuoteHeader.d.ts +12 -0
  14. package/dist/components/organisms/QuoteHeader/QuoteHeader.js +41 -0
  15. package/dist/components/organisms/QuoteHeader/constant.d.ts +3 -0
  16. package/dist/components/organisms/QuoteHeader/constant.js +8 -0
  17. package/dist/index.d.ts +4 -0
  18. package/dist/index.js +2 -0
  19. package/dist/styles/components/dropdown.css +7 -6
  20. package/dist/styles/components/forms.css +18 -9
  21. package/dist/styles/components/organism/multiple-quotation-docket.css +2304 -0
  22. package/package.json +1 -1
  23. package/src/components/atoms/Icon/icons/PlusCircleIcon.tsx +60 -0
  24. package/src/components/atoms/Icon/icons/QuotationIcon.tsx +50 -0
  25. package/src/components/atoms/Icon/icons/registry.tsx +4 -0
  26. package/src/components/atoms/Inputs/DropdownInput/DropdownInput.tsx +29 -17
  27. package/src/components/organisms/CarBookingCard/index.ts +1 -0
  28. package/src/components/organisms/MultipleQuotationDocket/MultipleQuotationDocket.tsx +349 -0
  29. package/src/components/organisms/MultipleQuotationDocket/index.ts +6 -0
  30. package/src/components/organisms/QuoteHeader/QuoteHeader.css +37 -0
  31. package/src/components/organisms/QuoteHeader/QuoteHeader.tsx +93 -0
  32. package/src/components/organisms/QuoteHeader/constant.ts +8 -0
  33. package/src/styles/components/dropdown.css +7 -6
  34. package/src/styles/components/forms.css +18 -11
  35. package/src/styles/components/organism/multiple-quotation-docket.css +222 -0
@@ -0,0 +1,93 @@
1
+ import React from 'react';
2
+ import Button from '../../atoms/Button/Button';
3
+ import DropdownInput from '../../atoms/Inputs/DropdownInput/DropdownInput';
4
+ import Input from '../../atoms/Inputs/Input/Input';
5
+ import { Heading } from '../../atoms/Typography/Typography';
6
+ import {
7
+ SORT_BY__FILE_STATUS_OPTIONS,
8
+ SORT_BY_CLIENT_TYPE_OPTIONS,
9
+ SORT_BY_DATE_OPTIONS,
10
+ } from './constant';
11
+ import './QuoteHeader.css';
12
+
13
+ export interface QuoteHeaderProps {
14
+ /** Current tab */
15
+ current: 'quotation' | 'booking';
16
+
17
+ /** Callback to navigate to a different tab */
18
+ onNavigate: (tab: 'quotation' | 'booking') => void;
19
+
20
+ /** Callback to create a new quote */
21
+ onNewQuote: () => void;
22
+
23
+ onFilterChange: (filter: 'date' | 'clientType' | 'fileStatus', value: string) => void;
24
+ }
25
+
26
+ const filterConfig = {
27
+ date: {
28
+ options: SORT_BY_DATE_OPTIONS,
29
+ placeholder: 'Sort by date',
30
+ },
31
+ clientType: {
32
+ options: SORT_BY_CLIENT_TYPE_OPTIONS,
33
+ placeholder: 'Client type',
34
+ },
35
+ fileStatus: {
36
+ options: SORT_BY__FILE_STATUS_OPTIONS,
37
+ placeholder: 'File status',
38
+ },
39
+ };
40
+
41
+ export const QuoteHeader: React.FC<QuoteHeaderProps> = (props) => {
42
+ const { current = 'quotation', onNavigate, onNewQuote, onFilterChange } = props;
43
+
44
+ return (
45
+ <div className="quote-header">
46
+ <Heading level={4} as="h1" className="quote-header__title" color="accent">
47
+ Quotation & Booking
48
+ </Heading>
49
+ <div className="flex gap-4">
50
+ <Button
51
+ variant={current === 'quotation' ? 'primary' : 'outline-primary'}
52
+ className="quote-header__button"
53
+ onClick={() => onNavigate('quotation')}>
54
+ Quotation
55
+ </Button>
56
+ <Button
57
+ variant={current === 'booking' ? 'primary' : 'outline-primary'}
58
+ className="quote-header__button"
59
+ onClick={() => onNavigate('booking')}>
60
+ Booking
61
+ </Button>
62
+ </div>
63
+ <div className="quote-header__search-container">
64
+ <Input
65
+ placeholder="Search"
66
+ icon="search"
67
+ iconPosition="leading"
68
+ className="quote-header__search"
69
+ />
70
+ <Button
71
+ variant="primary"
72
+ leadingIcon="plus-circle"
73
+ iconSize="md"
74
+ size="sm"
75
+ onClick={onNewQuote}>
76
+ New quote
77
+ </Button>
78
+ </div>
79
+ <div className="quote-header__filters">
80
+ {Object.entries(filterConfig).map(([key, value]) => (
81
+ <DropdownInput
82
+ key={key}
83
+ placeholder={value.placeholder}
84
+ options={value.options}
85
+ onSelect={(value) =>
86
+ onFilterChange(key as 'date' | 'clientType' | 'fileStatus', value)
87
+ }
88
+ />
89
+ ))}
90
+ </div>
91
+ </div>
92
+ );
93
+ };
@@ -0,0 +1,8 @@
1
+ export const SORT_BY_DATE_OPTIONS = ['Newest to oldest', 'Last week', 'Oldest to newest'];
2
+ export const SORT_BY_CLIENT_TYPE_OPTIONS = ['All', 'Standard', 'Honeymoon', 'Wedding'];
3
+ export const SORT_BY__FILE_STATUS_OPTIONS = [
4
+ 'All',
5
+ 'Free sales',
6
+ 'On request',
7
+ 'Pay to book',
8
+ ];
@@ -12,8 +12,8 @@
12
12
  width: 100%;
13
13
  min-height: 40px;
14
14
  padding: 8px 12px;
15
- border: 1px solid var(--color-slate-500, #6B7280);
16
- border-radius: 0.375rem;
15
+ border: 1px solid var(--color-slate-500, #6b7280);
16
+ border-radius: var(--input-border-radius-default);
17
17
  background-color: var(--color-white, #ffffff);
18
18
  cursor: pointer;
19
19
  transition: all 0.2s ease-in-out;
@@ -83,7 +83,7 @@
83
83
 
84
84
  .dropdown-input--disabled {
85
85
  background-color: var(--color-slate-100);
86
- border-color: var(--color-slate-300, #D1D5DB);
86
+ border-color: var(--color-slate-300, #d1d5db);
87
87
  cursor: not-allowed;
88
88
  }
89
89
 
@@ -104,10 +104,11 @@
104
104
  z-index: 1000;
105
105
  width: 100%;
106
106
  background-color: var(--color-white);
107
- border: 1px solid var(--color-neutral-400);
108
- border-top: 1px solid var(--color-neutral-400);
107
+ border: 1px solid var(--color-border-subtle);
109
108
  border-radius: var(--multiselect-border-radius, 0.75rem);
110
- box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
109
+ box-shadow:
110
+ 0 4px 6px -1px rgba(0, 0, 0, 0.1),
111
+ 0 2px 4px -1px rgba(0, 0, 0, 0.06);
111
112
  max-height: var(--multiselect-size-menu-max-height, 17.25rem);
112
113
  overflow-y: auto;
113
114
  padding: var(--spacing-padding-px-0);
@@ -1,10 +1,10 @@
1
1
  /* Styles Input centralisés: consomment uniquement des variables CSS issues de Style Dictionary */
2
2
 
3
3
  .input-field {
4
- font-family: var(--typography-font-family-sans, Inter,system-ui,sans-serif);
4
+ font-family: var(--typography-font-family-sans, Inter, system-ui, sans-serif);
5
5
  font-size: var(--input-font-size-default, 1rem);
6
6
  line-height: var(--input-line-height-default, 1.5rem);
7
- border-radius: 0.375rem;
7
+ border-radius: var(--input-border-radius-default);
8
8
  border-width: 1px;
9
9
  border-style: solid;
10
10
  padding: var(--input-padding-vertical, 0.5rem) var(--input-padding-horizontal, 0.75rem);
@@ -18,6 +18,7 @@
18
18
  .input-wrapper {
19
19
  position: relative;
20
20
  width: 100%;
21
+ height: 42px;
21
22
  }
22
23
 
23
24
  .input-icon {
@@ -29,15 +30,23 @@
29
30
  height: var(--input-search-iconSize, 1rem);
30
31
  }
31
32
 
32
- .input-icon--leading { left: var(--input-padding-horizontal, 0.75rem); }
33
- .input-icon--trailing { right: var(--input-padding-horizontal, 0.75rem); }
33
+ .input-icon--leading {
34
+ left: var(--input-padding-horizontal, 0.75rem);
35
+ }
36
+ .input-icon--trailing {
37
+ right: var(--input-padding-horizontal, 0.75rem);
38
+ }
34
39
 
35
40
  .input-field--with-icon.input-field--icon-leading {
36
- padding-left: calc(var(--input-padding-horizontal, 0.75rem) + var(--input-search-iconSize, 1rem) + 0.5rem);
41
+ padding-left: calc(
42
+ var(--input-padding-horizontal, 0.75rem) + var(--input-search-iconSize, 1rem) + 0.5rem
43
+ );
37
44
  }
38
45
 
39
46
  .input-field--with-icon.input-field--icon-trailing {
40
- padding-right: calc(var(--input-padding-horizontal, 0.75rem) + var(--input-search-iconSize, 1rem) + 0.5rem);
47
+ padding-right: calc(
48
+ var(--input-padding-horizontal, 0.75rem) + var(--input-search-iconSize, 1rem) + 0.5rem
49
+ );
41
50
  }
42
51
 
43
52
  .input-field:focus {
@@ -47,7 +56,7 @@
47
56
  /* État par défaut */
48
57
  .input-field--default {
49
58
  background-color: var(--color-white);
50
- border-color: var(--color-slate-300);
59
+ border-color: var(--color-tuna-500);
51
60
  color: var(--color-slate-900);
52
61
  }
53
62
 
@@ -110,7 +119,7 @@
110
119
  }
111
120
 
112
121
  .input-showcase h1 {
113
- font-family: var(--typography-font-family-sans, Inter,system-ui,sans-serif);
122
+ font-family: var(--typography-font-family-sans, Inter, system-ui, sans-serif);
114
123
  font-size: var(--typography-font-size-2xl, 1.5re);
115
124
  font-weight: var(--font-weight-font-bold);
116
125
  color: var(--color-slate-900);
@@ -118,7 +127,7 @@
118
127
  }
119
128
 
120
129
  .input-showcase h2 {
121
- font-family: var(--typography-font-family-sans, Inter,system-ui,sans-serif);
130
+ font-family: var(--typography-font-family-sans, Inter, system-ui, sans-serif);
122
131
  font-size: var(--typography-font-size-lg, 1.125rem);
123
132
  font-weight: var(--font-weight-font-medium);
124
133
  color: var(--color-slate-700);
@@ -143,5 +152,3 @@
143
152
  width: 100%;
144
153
  max-width: 300px;
145
154
  }
146
-
147
-
@@ -0,0 +1,222 @@
1
+ /* Multiple Quotation Docket Component */
2
+ .multiple-quotation-docket {
3
+ display: flex;
4
+ flex-direction: column;
5
+ gap: var(--spacing-gap-gap-6);
6
+ width: 100%;
7
+ }
8
+
9
+ /* Header */
10
+ .multiple-quotation-docket__header {
11
+ display: flex;
12
+ align-items: center;
13
+ justify-content: space-between;
14
+ width: 100%;
15
+ }
16
+
17
+ .multiple-quotation-docket__title {
18
+ display: flex;
19
+ align-items: center;
20
+ gap: var(--spacing-gap-gap-2);
21
+ }
22
+
23
+ .multiple-quotation-docket__title-text {
24
+ color: var(--color-text-default, #262626);
25
+ font-family: var(--font-font-family-heading, Satoshi);
26
+ font-size: var(--font-size-text-xl, 20px);
27
+ font-style: normal;
28
+ font-weight: var(--font-weight-font-bold, 700);
29
+ line-height: var(--font-leading-leading-lg, 28px);
30
+ letter-spacing: var(--font-tracking-tracking-normal, 0);
31
+ }
32
+
33
+ .multiple-quotation-docket__more-options {
34
+ cursor: pointer;
35
+ }
36
+
37
+ /* Services List */
38
+ .multiple-quotation-docket__services {
39
+ display: flex;
40
+ flex-direction: column;
41
+ gap: var(--spacing-gap-gap-6);
42
+ width: 100%;
43
+ }
44
+
45
+ .multiple-quotation-docket__service {
46
+ display: flex;
47
+ flex-direction: column;
48
+ gap: var(--spacing-gap-gap-4);
49
+ width: 100%;
50
+ }
51
+
52
+ .multiple-quotation-docket__service-header {
53
+ display: flex;
54
+ align-items: center;
55
+ justify-content: space-between;
56
+ width: 100%;
57
+ }
58
+
59
+ .multiple-quotation-docket__service-title {
60
+ display: flex;
61
+ align-items: center;
62
+ gap: var(--spacing-gap-gap-2);
63
+ }
64
+
65
+ .multiple-quotation-docket__section-bar {
66
+ width: 3px;
67
+ height: 20px;
68
+ background-color: var(--color-elevation-brand-subtle);
69
+ flex-shrink: 0;
70
+ }
71
+
72
+ /* Details */
73
+ .multiple-quotation-docket__details {
74
+ display: flex;
75
+ flex-direction: column;
76
+ gap: var(--spacing-gap-gap-3);
77
+ padding-left: var(--spacing-gap-gap-3);
78
+ width: 100%;
79
+ }
80
+
81
+ .multiple-quotation-docket__error {
82
+ width: 100%;
83
+ }
84
+
85
+ .multiple-quotation-docket__service-name {
86
+ width: 100%;
87
+ }
88
+
89
+ .multiple-quotation-docket__date-info {
90
+ display: flex;
91
+ flex-direction: column;
92
+ gap: var(--spacing-gap-gap-1);
93
+ width: 100%;
94
+ }
95
+
96
+ .multiple-quotation-docket__date-range {
97
+ display: flex;
98
+ align-items: center;
99
+ gap: var(--spacing-gap-gap-2);
100
+ }
101
+
102
+ .multiple-quotation-docket__client-info {
103
+ display: flex;
104
+ flex-direction: column;
105
+ gap: var(--spacing-gap-gap-1);
106
+ width: 100%;
107
+ }
108
+
109
+ .multiple-quotation-docket__client-type {
110
+ display: flex;
111
+ align-items: center;
112
+ gap: var(--spacing-gap-gap-0-5);
113
+ }
114
+
115
+ .multiple-quotation-docket__guests {
116
+ display: flex;
117
+ flex-direction: column;
118
+ gap: var(--spacing-gap-gap-1);
119
+ }
120
+
121
+ .multiple-quotation-docket__children {
122
+ display: flex;
123
+ align-items: center;
124
+ gap: var(--spacing-gap-gap-2);
125
+ }
126
+
127
+ .multiple-quotation-docket__child {
128
+ display: flex;
129
+ align-items: center;
130
+ gap: var(--spacing-gap-gap-2);
131
+ }
132
+
133
+ .multiple-quotation-docket__child-age {
134
+ color: var(--color-text-subtle);
135
+ opacity: 0.7;
136
+ }
137
+
138
+ .multiple-quotation-docket__room-info {
139
+ display: flex;
140
+ flex-direction: column;
141
+ gap: var(--spacing-gap-gap-2);
142
+ width: 100%;
143
+ }
144
+
145
+ .multiple-quotation-docket__meal-plan {
146
+ display: flex;
147
+ align-items: center;
148
+ gap: var(--spacing-gap-gap-2);
149
+ }
150
+
151
+ .multiple-quotation-docket__additional-details {
152
+ display: flex;
153
+ flex-direction: column;
154
+ gap: var(--spacing-gap-gap-1);
155
+ }
156
+
157
+ .multiple-quotation-docket__divider {
158
+ width: 0;
159
+ height: 14px;
160
+ border-left: 0.5px solid var(--color-border-medium);
161
+ }
162
+
163
+ /* Total Section */
164
+ .multiple-quotation-docket__total {
165
+ display: flex;
166
+ flex-direction: column;
167
+ gap: var(--spacing-gap-gap-2);
168
+ background-color: var(--color-elevation-level-2);
169
+ padding: var(--spacing-padding-py-0) var(--spacing-padding-px-0);
170
+ width: 100%;
171
+ }
172
+
173
+ .multiple-quotation-docket__total-line {
174
+ height: 0;
175
+ border-top: 0.5px solid var(--color-border-medium);
176
+ width: 100%;
177
+ }
178
+
179
+ .multiple-quotation-docket__total-content {
180
+ display: flex;
181
+ align-items: center;
182
+ justify-content: space-between;
183
+ padding: var(--spacing-padding-px-0) var(--spacing-padding-px-2);
184
+ width: 100%;
185
+ }
186
+
187
+ .multiple-quotation-docket__total-prices {
188
+ display: flex;
189
+ flex-direction: column;
190
+ align-items: flex-end;
191
+ gap: var(--spacing-gap-gap-1);
192
+ }
193
+
194
+ /* Actions */
195
+ .multiple-quotation-docket__actions {
196
+ display: flex;
197
+ flex-direction: column;
198
+ gap: var(--spacing-gap-gap-4);
199
+ width: 100%;
200
+ }
201
+
202
+ .multiple-quotation-docket__action-group {
203
+ display: flex;
204
+ align-items: flex-start;
205
+ justify-content: flex-end;
206
+ gap: var(--spacing-gap-gap-2);
207
+ width: 100%;
208
+ }
209
+
210
+ .multiple-quotation-docket__action-button {
211
+ width: 100%;
212
+ }
213
+
214
+ .multiple-quotation-docket__action-button--flex {
215
+ flex: 1;
216
+ min-width: 0;
217
+ }
218
+
219
+ .multiple-quotation-docket__action-button--book {
220
+ width: 162px;
221
+ flex-shrink: 0;
222
+ }