@voyantjs/bookings-react 0.53.1 → 0.54.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.
@@ -5,12 +5,12 @@ export interface UseBookingTaxPreviewOptions extends TaxPreviewFilters {
5
5
  /**
6
6
  * Real-time tax breakdown for the in-progress booking the operator is
7
7
  * configuring. The hook fires whenever `subtotalCents` changes so the
8
- * preview card reflects the customer-facing total as the operator
9
- * iterates on travelers / options / rooms.
8
+ * preview card reflects the customer-facing total as staff iterate on
9
+ * travelers / options / rooms.
10
10
  *
11
- * Wired to the template-level `/v1/admin/bookings/tax-preview` route —
12
- * resolved tax matches what will land on `booking_item_tax_lines` at
13
- * booking finalize.
11
+ * Wired to the mountable booking-tax `/v1/admin/bookings/tax-preview`
12
+ * route — resolved tax matches what will land on `booking_item_tax_lines`
13
+ * at booking finalize.
14
14
  */
15
15
  export declare function useBookingTaxPreview({ enabled, ...filters }: UseBookingTaxPreviewOptions): import("@tanstack/react-query").UseQueryResult<{
16
16
  data: {
@@ -5,12 +5,12 @@ import { getTaxPreviewQueryOptions } from "../query-options.js";
5
5
  /**
6
6
  * Real-time tax breakdown for the in-progress booking the operator is
7
7
  * configuring. The hook fires whenever `subtotalCents` changes so the
8
- * preview card reflects the customer-facing total as the operator
9
- * iterates on travelers / options / rooms.
8
+ * preview card reflects the customer-facing total as staff iterate on
9
+ * travelers / options / rooms.
10
10
  *
11
- * Wired to the template-level `/v1/admin/bookings/tax-preview` route —
12
- * resolved tax matches what will land on `booking_item_tax_lines` at
13
- * booking finalize.
11
+ * Wired to the mountable booking-tax `/v1/admin/bookings/tax-preview`
12
+ * route — resolved tax matches what will land on `booking_item_tax_lines`
13
+ * at booking finalize.
14
14
  */
15
15
  export function useBookingTaxPreview({ enabled = true, ...filters }) {
16
16
  const client = useVoyantBookingsContext();
@@ -2314,13 +2314,13 @@ export declare function getPricingPreviewQueryOptions(client: FetchWithValidatio
2314
2314
  };
2315
2315
  };
2316
2316
  /**
2317
- * Tax preview — resolves the operator's sell-side tax rate against an
2318
- * in-progress booking's subtotal so the booking-create dialog can show
2319
- * a real subtotal/tax/total breakdown.
2317
+ * Tax preview — resolves the configured sell-side tax rate against an
2318
+ * in-progress booking's subtotal so booking-create screens can show a
2319
+ * real subtotal/tax/total breakdown.
2320
2320
  *
2321
- * Backed by the template-level `/v1/admin/bookings/tax-preview` route,
2322
- * which mirrors the logic that runs at booking-finalize time. Numbers
2323
- * shown to the operator match what will land in
2321
+ * Backed by the mountable booking-tax `/v1/admin/bookings/tax-preview`
2322
+ * route, which mirrors the logic that runs at booking-finalize time.
2323
+ * Numbers shown to staff match what will land in
2324
2324
  * `booking_item_tax_lines`.
2325
2325
  */
2326
2326
  export declare function getTaxPreviewQueryOptions(client: FetchWithValidationOptions, filters: TaxPreviewFilters): import("@tanstack/react-query").OmitKeyof<import("@tanstack/react-query").UseQueryOptions<{
@@ -198,13 +198,13 @@ export function getPricingPreviewQueryOptions(client, filters) {
198
198
  });
199
199
  }
200
200
  /**
201
- * Tax preview — resolves the operator's sell-side tax rate against an
202
- * in-progress booking's subtotal so the booking-create dialog can show
203
- * a real subtotal/tax/total breakdown.
201
+ * Tax preview — resolves the configured sell-side tax rate against an
202
+ * in-progress booking's subtotal so booking-create screens can show a
203
+ * real subtotal/tax/total breakdown.
204
204
  *
205
- * Backed by the template-level `/v1/admin/bookings/tax-preview` route,
206
- * which mirrors the logic that runs at booking-finalize time. Numbers
207
- * shown to the operator match what will land in
205
+ * Backed by the mountable booking-tax `/v1/admin/bookings/tax-preview`
206
+ * route, which mirrors the logic that runs at booking-finalize time.
207
+ * Numbers shown to staff match what will land in
208
208
  * `booking_item_tax_lines`.
209
209
  */
210
210
  export function getTaxPreviewQueryOptions(client, filters) {
package/dist/schemas.js CHANGED
@@ -345,9 +345,9 @@ export const pricingPreviewSnapshotSchema = z.object({
345
345
  unitPrices: z.array(pricingPreviewUnitPriceSchema),
346
346
  });
347
347
  export const pricingPreviewResponse = singleEnvelope(pricingPreviewSnapshotSchema);
348
- // Tax preview — operator-side resolution of the tax line the booking
349
- // would carry given the current subtotal. Backed by the template-level
350
- // tax policy resolver.
348
+ // Tax preview — sell-side resolution of the tax line the booking
349
+ // would carry given the current subtotal. Backed by the mountable
350
+ // booking-tax route.
351
351
  const taxPreviewRateSchema = z.object({
352
352
  code: z.string(),
353
353
  label: z.string(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voyantjs/bookings-react",
3
- "version": "0.53.1",
3
+ "version": "0.54.0",
4
4
  "license": "Apache-2.0",
5
5
  "repository": {
6
6
  "type": "git",
@@ -41,7 +41,7 @@
41
41
  "react": "^19.0.0",
42
42
  "react-dom": "^19.0.0",
43
43
  "zod": "^4.0.0",
44
- "@voyantjs/bookings": "0.53.1"
44
+ "@voyantjs/bookings": "0.54.0"
45
45
  },
46
46
  "devDependencies": {
47
47
  "@tanstack/react-query": "^5.96.2",
@@ -52,12 +52,12 @@
52
52
  "typescript": "^6.0.2",
53
53
  "vitest": "^4.1.2",
54
54
  "zod": "^4.3.6",
55
- "@voyantjs/bookings": "0.53.1",
56
- "@voyantjs/react": "0.53.1",
55
+ "@voyantjs/bookings": "0.54.0",
56
+ "@voyantjs/react": "0.54.0",
57
57
  "@voyantjs/voyant-typescript-config": "0.1.0"
58
58
  },
59
59
  "dependencies": {
60
- "@voyantjs/react": "0.53.1"
60
+ "@voyantjs/react": "0.54.0"
61
61
  },
62
62
  "files": [
63
63
  "dist"