@travelswitchhq/flight-search-react 1.1.2 → 1.1.3

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/dist/index.cjs CHANGED
@@ -121,6 +121,9 @@ var flightSearchWidgetStyles = `
121
121
  .sw-container h5 {
122
122
  font-size: 14px;
123
123
  }
124
+ .sw-container .font14 {
125
+ font-size: 14px;
126
+ }
124
127
  .sw-container h6,
125
128
  .sw-container small {
126
129
  font-size: 12px;
@@ -868,6 +871,7 @@ padding-inline-start: 25px;
868
871
  flex: 1 1 50%;
869
872
  min-width: 0;
870
873
  justify-content: center;
874
+ border: 1px solid transparent;
871
875
  }
872
876
  .sw-add-return-label label {
873
877
  color: var(--primary) !important;
@@ -1345,8 +1349,8 @@ padding-inline-start: 25px;
1345
1349
  .sw-fsrh-chk-main{
1346
1350
  flex-wrap: wrap;
1347
1351
  }
1348
- .sw-custom-dropdown-trigger{
1349
- pointer-events: none;
1352
+ .mobiBox{
1353
+ flex-direction: row;
1350
1354
  }
1351
1355
  }
1352
1356
  `;
@@ -2159,8 +2163,9 @@ function FlightSearchWidget({
2159
2163
  "input",
2160
2164
  {
2161
2165
  type: "text",
2166
+ readOnly: true,
2162
2167
  id: `${dropdownType}-${segmentIndex}`,
2163
- className: `sw-custom-dropdown-trigger MobileHide ${value === placeholder || !value ? "sw-placeholder" : ""}`,
2168
+ className: `sw-custom-dropdown-trigger MobileShow ${value === placeholder || !value ? "sw-placeholder" : ""}`,
2164
2169
  value: value === placeholder ? "" : value ?? "",
2165
2170
  placeholder,
2166
2171
  onFocus: (e) => {
@@ -2180,9 +2185,8 @@ function FlightSearchWidget({
2180
2185
  "input",
2181
2186
  {
2182
2187
  type: "text",
2183
- readOnly: true,
2184
2188
  id: `${dropdownType}-${segmentIndex}`,
2185
- className: `sw-custom-dropdown-trigger MobileShow ${value === placeholder || !value ? "sw-placeholder" : ""}`,
2189
+ className: `sw-custom-dropdown-trigger MobileHide ${value === placeholder || !value ? "sw-placeholder" : ""}`,
2186
2190
  value: value === placeholder ? "" : value ?? "",
2187
2191
  placeholder,
2188
2192
  onFocus: (e) => {
@@ -2260,7 +2264,7 @@ function FlightSearchWidget({
2260
2264
  renderAirportDropdown(index, "destination", destinationDropdownRef || destinationRef, isDestOpen, () => toggleSegmentDropdown(index, "destination"))
2261
2265
  ] }, index),
2262
2266
  isMultiCityOrCustom && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "sw-srh-wrap sw-pos-rel", children: [
2263
- /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "sw-form-field sw-com-cal", children: [
2267
+ /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { className: "sw-form-field sw-com-cal ", children: [
2264
2268
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { htmlFor: `departure-${index}`, children: "Departure" }),
2265
2269
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
2266
2270
  import_calendar.Calendar,
@@ -2379,7 +2383,7 @@ function FlightSearchWidget({
2379
2383
  ),
2380
2384
  renderAirportDropdown(0, "destination", destinationDropdownRef, isDestinationDropdownOpen, () => setIsDestinationDropdownOpen(true))
2381
2385
  ] }),
2382
- (tripType === "round-trip" || tripType === "one-way") && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "sw-srh-wrap sw-pos-rel ", children: tripType === "round-trip" ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
2386
+ (tripType === "round-trip" || tripType === "one-way") && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "sw-srh-wrap sw-pos-rel mobiBox", children: tripType === "round-trip" ? /* @__PURE__ */ (0, import_jsx_runtime.jsxs)(import_jsx_runtime.Fragment, { children: [
2383
2387
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("div", { style: { cursor: "pointer" }, onClick: () => {
2384
2388
  dateRangeCalendarRef.current?.show?.();
2385
2389
  mobileDateRangeCalendarRef.current?.show?.();
@@ -2564,7 +2568,7 @@ function FlightSearchWidget({
2564
2568
  /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "sw-form-field sw-pos-rel sw-com-cal sw-add-return-label", style: { cursor: "pointer" }, onClick: () => {
2565
2569
  setTripType("round-trip");
2566
2570
  setTimeout(() => document.getElementById("dateRange")?.querySelector("input")?.focus?.(), 100);
2567
- }, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { children: "Add return" }) })
2571
+ }, children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)("label", { className: "font14", children: "Add return" }) })
2568
2572
  ] }) }),
2569
2573
  (tripType === "multi-city" || tripType === "custom-search") && /* @__PURE__ */ (0, import_jsx_runtime.jsx)("div", { className: "sw-srh-mc-foot", children: segments.length < getMaxSegments() && /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("button", { type: "button", className: "sw-srh-add-btn", onClick: addFlightSegment, children: [
2570
2574
  /* @__PURE__ */ (0, import_jsx_runtime.jsxs)("svg", { width: "14", height: "14", viewBox: "0 0 16 16", xmlns: "http://www.w3.org/2000/svg", children: [