@aifeatures/react 0.11.0 → 0.12.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.
package/dist/index.d.cts CHANGED
@@ -1340,8 +1340,9 @@ interface OrderSessionLineItem {
1340
1340
  */
1341
1341
  variant_id?: string;
1342
1342
  /**
1343
- * What ONE unit cost, in minor units of the order's `currency` — multiply
1344
- * by `quantity` for the line total, and display with `formatPrice`. Absent
1343
+ * Original price of ONE unit, in minor units of the order's `currency`.
1344
+ * Prefer `amount_net` for the paid line value; multiply this by `quantity`
1345
+ * only as a legacy fallback. Display with `formatPrice`. Absent
1345
1346
  * on orders taken before the field existed, so always guard.
1346
1347
  *
1347
1348
  * It is a LINE figure and the per-line values need NOT sum to
@@ -1350,6 +1351,14 @@ interface OrderSessionLineItem {
1350
1351
  * add the lines up and present the result as one.
1351
1352
  */
1352
1353
  unit_amount?: number;
1354
+ /** Final line amounts in minor units; net already includes inclusive tax. */
1355
+ amount_subtotal?: number;
1356
+ amount_discount?: number;
1357
+ amount_net?: number;
1358
+ amount_tax?: number;
1359
+ amount_total?: number;
1360
+ exclusive_tax?: number;
1361
+ unavailable_reason?: "oversold";
1353
1362
  /**
1354
1363
  * The product's first image as of checkout, for the line's thumbnail — the
1355
1364
  * same snapshot the merchant's order page renders. Absent on imageless
@@ -1421,6 +1430,9 @@ interface OrderSession {
1421
1430
  * it: that postage is already inside.
1422
1431
  */
1423
1432
  amount_total?: number;
1433
+ amount_subtotal?: number | null;
1434
+ discount_total?: number;
1435
+ exclusive_tax_total?: number | null;
1424
1436
  /**
1425
1437
  * The postage portion of `amount_total`, for pages that want to show a
1426
1438
  * breakdown row. `0` means postage was offered and came out free (a met
@@ -1484,7 +1496,7 @@ interface OrderConfirmationProps {
1484
1496
  }) => ReactNode;
1485
1497
  /** Rendered once the order is paid (covers download/redirect/plain) */
1486
1498
  renderPaid?: (session: OrderSession) => ReactNode;
1487
- /** Rendered for failed/expired (and refunded/disputed) orders */
1499
+ /** Rendered for failed/expired/disputed orders */
1488
1500
  renderFailed?: (session: OrderSession) => ReactNode;
1489
1501
  }
1490
1502
  declare function OrderConfirmation({ apiUrl: explicitApiUrl, className, style, sessionId: sessionIdProp, pollIntervalMs, pollTimeoutMs, followRedirect, redirectDelayMs, renderNoSession, renderPending, renderPaid, renderFailed, }: OrderConfirmationProps): react_jsx_runtime.JSX.Element | null;
package/dist/index.d.ts CHANGED
@@ -1340,8 +1340,9 @@ interface OrderSessionLineItem {
1340
1340
  */
1341
1341
  variant_id?: string;
1342
1342
  /**
1343
- * What ONE unit cost, in minor units of the order's `currency` — multiply
1344
- * by `quantity` for the line total, and display with `formatPrice`. Absent
1343
+ * Original price of ONE unit, in minor units of the order's `currency`.
1344
+ * Prefer `amount_net` for the paid line value; multiply this by `quantity`
1345
+ * only as a legacy fallback. Display with `formatPrice`. Absent
1345
1346
  * on orders taken before the field existed, so always guard.
1346
1347
  *
1347
1348
  * It is a LINE figure and the per-line values need NOT sum to
@@ -1350,6 +1351,14 @@ interface OrderSessionLineItem {
1350
1351
  * add the lines up and present the result as one.
1351
1352
  */
1352
1353
  unit_amount?: number;
1354
+ /** Final line amounts in minor units; net already includes inclusive tax. */
1355
+ amount_subtotal?: number;
1356
+ amount_discount?: number;
1357
+ amount_net?: number;
1358
+ amount_tax?: number;
1359
+ amount_total?: number;
1360
+ exclusive_tax?: number;
1361
+ unavailable_reason?: "oversold";
1353
1362
  /**
1354
1363
  * The product's first image as of checkout, for the line's thumbnail — the
1355
1364
  * same snapshot the merchant's order page renders. Absent on imageless
@@ -1421,6 +1430,9 @@ interface OrderSession {
1421
1430
  * it: that postage is already inside.
1422
1431
  */
1423
1432
  amount_total?: number;
1433
+ amount_subtotal?: number | null;
1434
+ discount_total?: number;
1435
+ exclusive_tax_total?: number | null;
1424
1436
  /**
1425
1437
  * The postage portion of `amount_total`, for pages that want to show a
1426
1438
  * breakdown row. `0` means postage was offered and came out free (a met
@@ -1484,7 +1496,7 @@ interface OrderConfirmationProps {
1484
1496
  }) => ReactNode;
1485
1497
  /** Rendered once the order is paid (covers download/redirect/plain) */
1486
1498
  renderPaid?: (session: OrderSession) => ReactNode;
1487
- /** Rendered for failed/expired (and refunded/disputed) orders */
1499
+ /** Rendered for failed/expired/disputed orders */
1488
1500
  renderFailed?: (session: OrderSession) => ReactNode;
1489
1501
  }
1490
1502
  declare function OrderConfirmation({ apiUrl: explicitApiUrl, className, style, sessionId: sessionIdProp, pollIntervalMs, pollTimeoutMs, followRedirect, redirectDelayMs, renderNoSession, renderPending, renderPaid, renderFailed, }: OrderConfirmationProps): react_jsx_runtime.JSX.Element | null;