@odynn/awayz-core 0.10.0 → 0.10.1

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.
@@ -128,6 +128,7 @@ export interface IFlightBookingDetails {
128
128
  flights: IFlight[];
129
129
  availableActions: string[];
130
130
  airlineInitiatedChanges: IAirlineInitiatedChanges[];
131
+ services: IConfirmedFlightService[];
131
132
  }
132
133
  export interface IFlight {
133
134
  origin: IAirport;
@@ -156,3 +157,20 @@ export interface IAirlineInitiatedChanges {
156
157
  added: ISlice[];
157
158
  removed: ISlice[];
158
159
  }
160
+ export interface IConfirmedFlightService {
161
+ segmentIds: string[];
162
+ passengerIds: string[];
163
+ totalCurrency: string;
164
+ quantity: number;
165
+ metadata?: IFlightServiceMetadata;
166
+ totalAmount: string;
167
+ type: string;
168
+ id: string;
169
+ }
170
+ export interface IFlightServiceMetadata {
171
+ disclosures: string[];
172
+ designator: string;
173
+ name: any;
174
+ type: string;
175
+ maximumWeightKg: number;
176
+ }
@@ -2,7 +2,7 @@ var g = Object.defineProperty;
2
2
  var f = (c, t, a) => t in c ? g(c, t, { enumerable: !0, configurable: !0, writable: !0, value: a }) : c[t] = a;
3
3
  var r = (c, t, a) => f(c, typeof t != "symbol" ? t + "" : t, a);
4
4
  import "../../arrayExtensions-DlcBOj5a.js";
5
- import { c as l, b as _, g as p } from "../../noRetryInstance-C4bqpBc7.js";
5
+ import { c as l, b as m, g as p } from "../../noRetryInstance-C4bqpBc7.js";
6
6
  import "react";
7
7
  import { EBookingEndpoints as i } from "../../configs/endpoints.js";
8
8
  const y = (c) => {
@@ -54,12 +54,12 @@ class h {
54
54
  longitude: a.data.accommodation.location.geographic_coordinates.longitude
55
55
  },
56
56
  images: a.data.accommodation.photos.map((o) => o.url),
57
- guests: a.data.guests.map((o, m) => {
57
+ guests: a.data.guests.map((o, _) => {
58
58
  var u;
59
59
  return {
60
60
  familyName: o.family_name,
61
61
  givenName: o.given_name,
62
- type: (u = a.data.guest_types[m]) == null ? void 0 : u.type
62
+ type: (u = a.data.guest_types[_]) == null ? void 0 : u.type
63
63
  };
64
64
  }),
65
65
  numberOfRooms: (s = a.data.rooms) == null ? void 0 : s.length,
@@ -71,9 +71,9 @@ class h {
71
71
  })
72
72
  ),
73
73
  rooms: (e = a.data.rooms) == null ? void 0 : e.map((o) => {
74
- var m;
74
+ var _;
75
75
  return {
76
- beds: (m = o.beds) == null ? void 0 : m.map((u) => ({
76
+ beds: (_ = o.beds) == null ? void 0 : _.map((u) => ({
77
77
  type: u.type,
78
78
  count: u.count
79
79
  })),
@@ -138,12 +138,12 @@ class h {
138
138
  numberOfStops: e.segments.length - 1,
139
139
  reference: a.data.booking_reference,
140
140
  durationInMinutes: y(e.duration),
141
- origin: _(e.origin),
142
- destination: _(e.destination),
143
- segments: _(e.segments)
141
+ origin: m(e.origin),
142
+ destination: m(e.destination),
143
+ segments: m(e.segments)
144
144
  })),
145
145
  availableActions: a.data.available_actions,
146
- airlineInitiatedChanges: _(a.data.airline_initiated_changes) || [],
146
+ airlineInitiatedChanges: m(a.data.airline_initiated_changes) || [],
147
147
  cancellationDetails: a.data.cancellation_details ? {
148
148
  refundAmount: parseFloat(
149
149
  a.data.cancellation_details.refund_amount
@@ -151,7 +151,8 @@ class h {
151
151
  refundCurrency: a.data.cancellation_details.refund_currency,
152
152
  refundTo: a.data.cancellation_details.refund_to,
153
153
  confirmedAt: a.data.cancellation_details.confirmed_at
154
- } : void 0
154
+ } : void 0,
155
+ services: m(a.data.services)
155
156
  };
156
157
  });
157
158
  r(this, "initiateCancelFlightBooking", async (t) => {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@odynn/awayz-core",
3
- "version": "0.10.0",
3
+ "version": "0.10.1",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "dist"
@@ -29,6 +29,7 @@
29
29
  "@types/node": "^22.10.7",
30
30
  "@types/react": "^18.3.18",
31
31
  "@types/react-dom": "^18.3.5",
32
+ "@type-op/shared": "^1.0.0",
32
33
  "@vitejs/plugin-react": "^4.3.4",
33
34
  "axios": "^1.7.9",
34
35
  "eslint": "^9.17.0",