mautourco-components 0.2.14 → 0.2.16

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 (57) hide show
  1. package/dist/components/atoms/Icon/icons/BusIcon.js +1 -1
  2. package/dist/components/atoms/Icon/icons/PlusCircleIcon.d.ts +12 -0
  3. package/dist/components/atoms/Icon/icons/PlusCircleIcon.js +36 -0
  4. package/dist/components/atoms/Icon/icons/registry.d.ts +1 -0
  5. package/dist/components/atoms/Icon/icons/registry.js +2 -0
  6. package/dist/components/atoms/Inputs/DropdownInput/DropdownInput.js +15 -3
  7. package/dist/components/molecules/Breadcrumbs/Breadcrumbs.css +2097 -0
  8. package/dist/components/molecules/Breadcrumbs/Breadcrumbs.d.ts +11 -0
  9. package/dist/components/molecules/Breadcrumbs/Breadcrumbs.js +20 -0
  10. package/dist/components/molecules/TableServiceItem/DetailsCol.d.ts +2 -2
  11. package/dist/components/molecules/TableServiceItem/DetailsCol.js +3 -2
  12. package/dist/components/molecules/TextWithIcon/TextWithIcon.js +2 -2
  13. package/dist/components/molecules/TimelineItem/ServiceAccommodation.d.ts +9 -0
  14. package/dist/components/molecules/TimelineItem/ServiceAccommodation.js +20 -0
  15. package/dist/components/molecules/TimelineItem/ServiceExcursion.d.ts +8 -0
  16. package/dist/components/molecules/TimelineItem/ServiceExcursion.js +20 -0
  17. package/dist/components/molecules/TimelineItem/ServiceTransfer.d.ts +11 -0
  18. package/dist/components/molecules/TimelineItem/ServiceTransfer.js +19 -0
  19. package/dist/components/molecules/TimelineItem/TimelineHeader.css +2166 -0
  20. package/dist/components/molecules/TimelineItem/TimelineHeader.d.ts +10 -0
  21. package/dist/components/molecules/TimelineItem/TimelineHeader.js +21 -0
  22. package/dist/components/molecules/TimelineItem/TimelineItem.css +2084 -0
  23. package/dist/components/molecules/TimelineItem/TimelineItem.d.ts +12 -0
  24. package/dist/components/molecules/TimelineItem/TimelineItem.js +23 -0
  25. package/dist/components/organisms/QuoteHeader/QuoteHeader.css +2142 -0
  26. package/dist/components/organisms/QuoteHeader/QuoteHeader.d.ts +12 -0
  27. package/dist/components/organisms/QuoteHeader/QuoteHeader.js +41 -0
  28. package/dist/components/organisms/QuoteHeader/constant.d.ts +3 -0
  29. package/dist/components/organisms/QuoteHeader/constant.js +8 -0
  30. package/dist/components/organisms/Timeline/Timeline.d.ts +14 -0
  31. package/dist/components/organisms/Timeline/Timeline.js +19 -0
  32. package/dist/index.d.ts +9 -0
  33. package/dist/index.js +3 -0
  34. package/dist/styles/components/dropdown.css +7 -6
  35. package/dist/styles/components/forms.css +18 -9
  36. package/package.json +1 -1
  37. package/src/components/atoms/Icon/icons/BusIcon.tsx +6 -2
  38. package/src/components/atoms/Icon/icons/PlusCircleIcon.tsx +60 -0
  39. package/src/components/atoms/Icon/icons/registry.tsx +2 -0
  40. package/src/components/atoms/Inputs/DropdownInput/DropdownInput.tsx +29 -17
  41. package/src/components/molecules/Breadcrumbs/Breadcrumbs.css +10 -0
  42. package/src/components/molecules/Breadcrumbs/Breadcrumbs.tsx +47 -0
  43. package/src/components/molecules/TableServiceItem/DetailsCol.tsx +9 -5
  44. package/src/components/molecules/TextWithIcon/TextWithIcon.tsx +19 -5
  45. package/src/components/molecules/TimelineItem/ServiceAccommodation.tsx +29 -0
  46. package/src/components/molecules/TimelineItem/ServiceExcursion.tsx +28 -0
  47. package/src/components/molecules/TimelineItem/ServiceTransfer.tsx +25 -0
  48. package/src/components/molecules/TimelineItem/TimelineHeader.css +44 -0
  49. package/src/components/molecules/TimelineItem/TimelineHeader.tsx +41 -0
  50. package/src/components/molecules/TimelineItem/TimelineItem.css +7 -0
  51. package/src/components/molecules/TimelineItem/TimelineItem.tsx +17 -0
  52. package/src/components/organisms/QuoteHeader/QuoteHeader.css +37 -0
  53. package/src/components/organisms/QuoteHeader/QuoteHeader.tsx +93 -0
  54. package/src/components/organisms/QuoteHeader/constant.ts +8 -0
  55. package/src/components/organisms/Timeline/Timeline.tsx +57 -0
  56. package/src/styles/components/dropdown.css +7 -6
  57. package/src/styles/components/forms.css +18 -11
@@ -31,6 +31,6 @@ var BusIcon = function (_a) {
31
31
  var sizeClasses = getSizeClasses();
32
32
  var colorClass = color ? "text-".concat(color) : 'text-current';
33
33
  var classes = "".concat(sizeClasses, " ").concat(colorClass, " ").concat(className);
34
- return (_jsxs("svg", __assign({ className: classes, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [_jsx("g", __assign({ "clip-path": "url(#clip0_7033_40084)" }, { children: _jsx("path", { d: "M12.5821 8.08301H3.41512V11.333C3.41512 11.6552 3.67694 11.917 3.99911 11.917H11.9991C12.3211 11.9168 12.5821 11.6551 12.5821 11.333V8.08301ZM5.33895 9.25L5.41512 9.25391C5.79348 9.29216 6.08895 9.61156 6.08895 10C6.08895 10.3884 5.79348 10.7078 5.41512 10.7461L5.33895 10.75H5.33211C4.9179 10.75 4.58211 10.4142 4.58211 10C4.58211 9.58579 4.9179 9.25 5.33211 9.25H5.33895ZM10.672 9.25C11.0862 9.25 11.422 9.58579 11.422 10C11.422 10.4142 11.0862 10.75 10.672 10.75H10.6651C10.2511 10.7498 9.91512 10.4141 9.91512 10C9.91512 9.5859 10.2511 9.25018 10.6651 9.25H10.672ZM3.99911 2.75C3.67705 2.75 3.4153 3.01099 3.41512 3.33301V6.58301H12.5821V3.33301C12.5819 3.0111 12.321 2.75018 11.9991 2.75H3.99911ZM9.33211 3.25C9.74633 3.25 10.0821 3.58579 10.0821 4C10.0821 4.41421 9.74633 4.75 9.33211 4.75H6.66512C6.25106 4.74982 5.91512 4.41411 5.91512 4C5.91512 3.58589 6.25106 3.25018 6.66512 3.25H9.33211ZM14.0821 11.333C14.0821 12.2187 13.5284 12.973 12.7491 13.2744V14C12.7491 14.4141 12.4132 14.7498 11.9991 14.75C11.5849 14.75 11.2491 14.4142 11.2491 14V13.417H4.74911V14C4.74911 14.4141 4.41317 14.7498 3.99911 14.75C3.58489 14.75 3.24911 14.4142 3.24911 14V13.2754C2.46934 12.9742 1.91512 12.219 1.91512 11.333V5.21387L1.66708 5.33789C1.29669 5.52273 0.846371 5.37226 0.661216 5.00195C0.476074 4.63149 0.626713 4.18131 0.997153 3.99609L1.91512 3.53613V3.33301C1.9153 2.18256 2.84862 1.25 3.99911 1.25H11.9991C13.1494 1.25018 14.0819 2.18267 14.0821 3.33301V3.53613L15.0011 3.99609C15.3714 4.18142 15.5212 4.63156 15.336 5.00195C15.1508 5.37235 14.7006 5.52293 14.3302 5.33789L14.0821 5.21289V11.333Z", fill: "#303642" }) })), _jsx("defs", { children: _jsx("clipPath", __assign({ id: "clip0_7033_40084" }, { children: _jsx("rect", { width: "16", height: "16", fill: "white" }) })) })] })));
34
+ return (_jsxs("svg", __assign({ className: classes, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [_jsx("g", __assign({ "clip-path": "url(#clip0_7033_40084)" }, { children: _jsx("path", { d: "M12.5821 8.08301H3.41512V11.333C3.41512 11.6552 3.67694 11.917 3.99911 11.917H11.9991C12.3211 11.9168 12.5821 11.6551 12.5821 11.333V8.08301ZM5.33895 9.25L5.41512 9.25391C5.79348 9.29216 6.08895 9.61156 6.08895 10C6.08895 10.3884 5.79348 10.7078 5.41512 10.7461L5.33895 10.75H5.33211C4.9179 10.75 4.58211 10.4142 4.58211 10C4.58211 9.58579 4.9179 9.25 5.33211 9.25H5.33895ZM10.672 9.25C11.0862 9.25 11.422 9.58579 11.422 10C11.422 10.4142 11.0862 10.75 10.672 10.75H10.6651C10.2511 10.7498 9.91512 10.4141 9.91512 10C9.91512 9.5859 10.2511 9.25018 10.6651 9.25H10.672ZM3.99911 2.75C3.67705 2.75 3.4153 3.01099 3.41512 3.33301V6.58301H12.5821V3.33301C12.5819 3.0111 12.321 2.75018 11.9991 2.75H3.99911ZM9.33211 3.25C9.74633 3.25 10.0821 3.58579 10.0821 4C10.0821 4.41421 9.74633 4.75 9.33211 4.75H6.66512C6.25106 4.74982 5.91512 4.41411 5.91512 4C5.91512 3.58589 6.25106 3.25018 6.66512 3.25H9.33211ZM14.0821 11.333C14.0821 12.2187 13.5284 12.973 12.7491 13.2744V14C12.7491 14.4141 12.4132 14.7498 11.9991 14.75C11.5849 14.75 11.2491 14.4142 11.2491 14V13.417H4.74911V14C4.74911 14.4141 4.41317 14.7498 3.99911 14.75C3.58489 14.75 3.24911 14.4142 3.24911 14V13.2754C2.46934 12.9742 1.91512 12.219 1.91512 11.333V5.21387L1.66708 5.33789C1.29669 5.52273 0.846371 5.37226 0.661216 5.00195C0.476074 4.63149 0.626713 4.18131 0.997153 3.99609L1.91512 3.53613V3.33301C1.9153 2.18256 2.84862 1.25 3.99911 1.25H11.9991C13.1494 1.25018 14.0819 2.18267 14.0821 3.33301V3.53613L15.0011 3.99609C15.3714 4.18142 15.5212 4.63156 15.336 5.00195C15.1508 5.37235 14.7006 5.52293 14.3302 5.33789L14.0821 5.21289V11.333Z", fill: "currentColor" }) })), _jsx("defs", { children: _jsx("clipPath", __assign({ id: "clip0_7033_40084" }, { children: _jsx("rect", { width: "16", height: "16", fill: "white" }) })) })] })));
35
35
  };
36
36
  export default BusIcon;
@@ -0,0 +1,12 @@
1
+ import React from 'react';
2
+ interface PlusCircleIconProps {
3
+ size?: 'xs' | 'sm' | 'md' | 'lg' | 'xl';
4
+ className?: string;
5
+ color?: string;
6
+ /**
7
+ * Couleur par défaut si aucune couleur n'est spécifiée
8
+ */
9
+ defaultColor?: string;
10
+ }
11
+ declare const PlusCircleIcon: React.FC<PlusCircleIconProps>;
12
+ export default PlusCircleIcon;
@@ -0,0 +1,36 @@
1
+ var __assign = (this && this.__assign) || function () {
2
+ __assign = Object.assign || function(t) {
3
+ for (var s, i = 1, n = arguments.length; i < n; i++) {
4
+ s = arguments[i];
5
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))
6
+ t[p] = s[p];
7
+ }
8
+ return t;
9
+ };
10
+ return __assign.apply(this, arguments);
11
+ };
12
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
+ var PlusCircleIcon = function (_a) {
14
+ var _b = _a.size, size = _b === void 0 ? 'md' : _b, _c = _a.className, className = _c === void 0 ? '' : _c, color = _a.color;
15
+ var getSizeClasses = function () {
16
+ switch (size) {
17
+ case 'xs':
18
+ return 'w-3 h-3';
19
+ case 'sm':
20
+ return 'w-4 h-4';
21
+ case 'md':
22
+ return 'w-5 h-5';
23
+ case 'lg':
24
+ return 'w-6 h-6';
25
+ case 'xl':
26
+ return 'w-8 h-8';
27
+ default:
28
+ return 'w-5 h-5';
29
+ }
30
+ };
31
+ var sizeClasses = getSizeClasses();
32
+ var colorClass = color ? "text-".concat(color) : 'text-current';
33
+ var classes = "".concat(sizeClasses, " ").concat(colorClass, " ").concat(className);
34
+ return (_jsxs("svg", __assign({ className: classes, viewBox: "0 0 16 16", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, { children: [_jsx("g", __assign({ "clip-path": "url(#clip0_7074_66340)" }, { children: _jsx("path", { d: "M13.915 8.00098C13.915 4.7334 11.2666 2.08416 7.99902 2.08398C4.73134 2.08398 2.08203 4.73329 2.08203 8.00098C2.08221 11.2685 4.73145 13.917 7.99902 13.917C11.2664 13.9168 13.9149 11.2684 13.915 8.00098ZM7.24902 10.667V8.75098H5.33203C4.91793 8.75098 4.58221 8.41504 4.58203 8.00098C4.58203 7.58676 4.91782 7.25098 5.33203 7.25098H7.24902V5.33398C7.24902 4.91977 7.58481 4.58398 7.99902 4.58398C8.41309 4.58416 8.74902 4.91988 8.74902 5.33398V7.25098H10.665L10.7422 7.25488C11.1203 7.29337 11.415 7.61271 11.415 8.00098C11.4149 8.38912 11.1202 8.70862 10.7422 8.74707L10.665 8.75098H8.74902V10.667C8.74902 11.0811 8.41309 11.4168 7.99902 11.417C7.58481 11.417 7.24902 11.0812 7.24902 10.667ZM15.415 8.00098C15.4149 12.0968 12.0949 15.4168 7.99902 15.417C3.90302 15.417 0.582208 12.0969 0.582031 8.00098C0.582031 3.90487 3.90291 0.583984 7.99902 0.583984C12.095 0.584161 15.415 3.90497 15.415 8.00098Z", fill: "white" }) })), _jsx("defs", { children: _jsx("clipPath", __assign({ id: "clip0_7074_66340" }, { children: _jsx("rect", { width: "16", height: "16", fill: "white" }) })) })] })));
35
+ };
36
+ export default PlusCircleIcon;
@@ -63,5 +63,6 @@ export declare const ICONS: {
63
63
  readonly bus: IconComponent;
64
64
  readonly map: IconComponent;
65
65
  readonly wallet: IconComponent;
66
+ readonly 'plus-circle': IconComponent;
66
67
  };
67
68
  export type IconName = keyof typeof ICONS;
@@ -45,6 +45,7 @@ import NightIcon from './NightIcon';
45
45
  import PlaneIcon from './PlaneIcon';
46
46
  import PlaneLandingOutlineIcon from './PlaneLandingOutlineIcon';
47
47
  import PlaneTakeoffOutlineIcon from './PlaneTakeoffOutlineIcon';
48
+ import PlusCircleIcon from './PlusCircleIcon';
48
49
  import PlusIcon from './PlusIcon';
49
50
  import QuotationIcon from './QuotationIcon';
50
51
  import Search from './Search';
@@ -120,4 +121,5 @@ export var ICONS = {
120
121
  bus: BusIcon,
121
122
  map: MapIcon,
122
123
  wallet: WalletIcon,
124
+ 'plus-circle': PlusCircleIcon,
123
125
  };
@@ -10,12 +10,13 @@ var __assign = (this && this.__assign) || function () {
10
10
  return __assign.apply(this, arguments);
11
11
  };
12
12
  import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
13
- import { useState } from 'react';
13
+ import { useEffect, useRef, useState } from 'react';
14
14
  import Icon from '../../Icon/Icon';
15
15
  import Spinner from '../../Spinner/Spinner';
16
16
  var DropdownInput = function (_a) {
17
17
  var _b = _a.placeholder, placeholder = _b === void 0 ? 'Select item name' : _b, value = _a.value, _c = _a.state, state = _c === void 0 ? 'default' : _c, onClick = _a.onClick, _d = _a.className, className = _d === void 0 ? '' : _d, _e = _a.options, options = _e === void 0 ? [] : _e, onSelect = _a.onSelect;
18
18
  var _f = useState(false), isOpen = _f[0], setIsOpen = _f[1];
19
+ var dropdownRef = useRef(null);
19
20
  var handleClick = function () {
20
21
  if (state === 'disabled' || state === 'loading')
21
22
  return;
@@ -47,7 +48,18 @@ var DropdownInput = function (_a) {
47
48
  }
48
49
  return (_jsx(Icon, { name: isOpen ? 'chevron-up' : 'chevron-down', size: "sm", className: "dropdown-input__icon dropdown-input__icon--chevron" }));
49
50
  };
50
- var displayText = state === 'loading' ? 'Loading...' : (value || placeholder);
51
- return (_jsxs("div", __assign({ className: "dropdown-container ".concat(className) }, { children: [_jsxs("div", __assign({ className: "dropdown-input ".concat(getStateClasses()), onClick: handleClick }, { children: [_jsx("span", __assign({ className: "dropdown-input__text" }, { children: displayText })), getIcon()] })), isOpen && options.length > 0 && (_jsx("div", __assign({ className: "dropdown-menu" }, { children: options.map(function (option, index) { return (_jsx("div", __assign({ className: "dropdown-option", onClick: function () { return handleOptionSelect(option); } }, { children: option }), index)); }) })))] })));
51
+ var displayText = state === 'loading' ? 'Loading...' : value || placeholder;
52
+ useEffect(function () {
53
+ var handleClickOutside = function (event) {
54
+ if (dropdownRef.current && !dropdownRef.current.contains(event.target)) {
55
+ setIsOpen(false);
56
+ }
57
+ };
58
+ document.addEventListener('mousedown', handleClickOutside);
59
+ return function () {
60
+ document.removeEventListener('mousedown', handleClickOutside);
61
+ };
62
+ }, []);
63
+ return (_jsxs("div", __assign({ ref: dropdownRef, className: "dropdown-container ".concat(className) }, { children: [_jsxs("div", __assign({ className: "dropdown-input ".concat(getStateClasses()), onClick: handleClick }, { children: [_jsx("span", __assign({ className: "dropdown-input__text" }, { children: displayText })), getIcon()] })), isOpen && options.length > 0 && (_jsx("div", __assign({ className: "dropdown-menu" }, { children: options.map(function (option, index) { return (_jsx("div", __assign({ className: "dropdown-option", onClick: function () { return handleOptionSelect(option); } }, { children: option }), index)); }) })))] })));
52
64
  };
53
65
  export default DropdownInput;