autumn-js 0.1.38 → 0.1.40

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 (22) hide show
  1. package/dist/libraries/backend/better-auth.d.mts +2 -1
  2. package/dist/libraries/backend/better-auth.d.ts +2 -1
  3. package/dist/libraries/react/{chunk-DEPJ74S4.mjs → chunk-GGJKNVL6.mjs} +27 -26
  4. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.css +6 -0
  5. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.d.mts +1 -1
  6. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.d.ts +1 -1
  7. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.js +4894 -4891
  8. package/dist/libraries/react/components/checkout-dialog/checkout-dialog-synced.mjs +11 -11
  9. package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.css +6 -0
  10. package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.js +94 -94
  11. package/dist/libraries/react/components/paywall-dialog/paywall-dialog-synced.mjs +11 -11
  12. package/dist/libraries/react/components/pricing-table/pricing-table-synced.css +6 -0
  13. package/dist/libraries/react/components/pricing-table/pricing-table-synced.js +543 -540
  14. package/dist/libraries/react/components/pricing-table/pricing-table-synced.mjs +11 -11
  15. package/dist/libraries/react/components/ui/dialog.mjs +2 -2
  16. package/dist/libraries/react/components/ui/popover.mjs +2 -2
  17. package/dist/libraries/react/index.js +544 -541
  18. package/dist/libraries/react/index.mjs +545 -542
  19. package/dist/styles/global.css +6 -0
  20. package/package.json +2 -2
  21. package/dist/libraries/react/{chunk-YCHPTRJA.mjs → chunk-I274Z7T2.mjs} +3 -3
  22. package/dist/libraries/react/{chunk-47KEC6LH.mjs → chunk-MHAXHLX4.mjs} +3 -3
@@ -1,3 +1,4 @@
1
+ import * as better_call from 'better-call';
1
2
  import { Middleware } from 'better-auth';
2
3
  import { z } from 'zod/v4';
3
4
  import { AutumnOptions } from './utils/betterAuth/types.mjs';
@@ -27,7 +28,7 @@ declare const autumn: (options?: AutumnOptions) => {
27
28
  } & {
28
29
  asResponse?: boolean;
29
30
  returnHeaders?: boolean;
30
- use?: Middleware[];
31
+ use?: better_call.Middleware[];
31
32
  path?: string;
32
33
  } & {
33
34
  asResponse?: AsResponse | undefined;
@@ -1,3 +1,4 @@
1
+ import * as better_call from 'better-call';
1
2
  import { Middleware } from 'better-auth';
2
3
  import { z } from 'zod/v4';
3
4
  import { AutumnOptions } from './utils/betterAuth/types.js';
@@ -27,7 +28,7 @@ declare const autumn: (options?: AutumnOptions) => {
27
28
  } & {
28
29
  asResponse?: boolean;
29
30
  returnHeaders?: boolean;
30
- use?: Middleware[];
31
+ use?: better_call.Middleware[];
31
32
  path?: string;
32
33
  } & {
33
34
  asResponse?: AsResponse | undefined;
@@ -1,8 +1,25 @@
1
1
  "use client";
2
2
 
3
+ import {
4
+ getPricingTableContent
5
+ } from "./chunk-URQMBRFZ.mjs";
6
+ import {
7
+ Input
8
+ } from "./chunk-GUM4HIGI.mjs";
9
+ import {
10
+ Popover,
11
+ PopoverContent,
12
+ PopoverTrigger
13
+ } from "./chunk-I274Z7T2.mjs";
14
+ import {
15
+ Switch
16
+ } from "./chunk-2LZIBRD4.mjs";
3
17
  import {
4
18
  getPaywallContent
5
19
  } from "./chunk-I5ZGIAIX.mjs";
20
+ import {
21
+ getCheckoutContent
22
+ } from "./chunk-BLM4DAAR.mjs";
6
23
  import {
7
24
  Accordion,
8
25
  AccordionContent,
@@ -18,36 +35,16 @@ import {
18
35
  DialogContent,
19
36
  DialogFooter,
20
37
  DialogTitle
21
- } from "./chunk-47KEC6LH.mjs";
38
+ } from "./chunk-MHAXHLX4.mjs";
22
39
  import {
23
40
  ArrowRight,
24
41
  ChevronDown,
25
42
  LoaderCircle
26
43
  } from "./chunk-2OHJ6PS6.mjs";
27
- import {
28
- Input
29
- } from "./chunk-GUM4HIGI.mjs";
30
- import {
31
- Popover,
32
- PopoverContent,
33
- PopoverTrigger
34
- } from "./chunk-YCHPTRJA.mjs";
35
- import {
36
- Switch
37
- } from "./chunk-2LZIBRD4.mjs";
38
- import {
39
- getCheckoutContent
40
- } from "./chunk-BLM4DAAR.mjs";
41
- import {
42
- getPricingTableContent
43
- } from "./chunk-URQMBRFZ.mjs";
44
44
  import {
45
45
  loadingStyles,
46
46
  spinnerStyles
47
47
  } from "./chunk-WVKYZYFT.mjs";
48
- import {
49
- useCustomer
50
- } from "./chunk-HEKBPI6U.mjs";
51
48
  import {
52
49
  usePaywall
53
50
  } from "./chunk-ZQPCEJFK.mjs";
@@ -57,6 +54,9 @@ import {
57
54
  import {
58
55
  cn
59
56
  } from "./chunk-4J6OC4ZQ.mjs";
57
+ import {
58
+ useCustomer
59
+ } from "./chunk-HEKBPI6U.mjs";
60
60
 
61
61
  // src/libraries/react/components/checkout-dialog/checkout-dialog-synced.tsx
62
62
  import { useEffect, useState } from "react";
@@ -218,7 +218,7 @@ function CheckoutLines({ checkoutResult }) {
218
218
  }
219
219
  )
220
220
  ] }) }),
221
- /* @__PURE__ */ jsx(AccordionContent, { className: "au-mt-2 au-mb-0 au-pb-2 au-flex au-flex-col au-gap-2", children: checkoutResult?.lines.filter((line) => line.amount != 0).map((line, index) => {
221
+ /* @__PURE__ */ jsx(AccordionContent, { className: "au-mt-2 au-mb-0 au-pb-2 au-flex au-flex-col au-gap-2", children: checkoutResult?.lines.filter((line) => line.amount !== 0).map((line, index) => {
222
222
  return /* @__PURE__ */ jsxs("div", { className: "au-flex au-justify-between", children: [
223
223
  /* @__PURE__ */ jsx("p", { className: "au-text-muted-foreground", children: line.description }),
224
224
  /* @__PURE__ */ jsx("p", { className: "au-text-muted-foreground", children: new Intl.NumberFormat("en-US", {
@@ -300,13 +300,14 @@ var PrepaidItem = ({
300
300
  {
301
301
  className: cn(
302
302
  "au-text-muted-foreground au-text-xs au-px-1 au-py-0.5 au-rounded-md au-flex au-items-center au-gap-1 au-bg-accent/80 au-shrink-0",
303
- disableSelection !== true && "hover:au-bg-accent hover:au-text-foreground"
303
+ disableSelection !== true && "hover:au-bg-accent hover:au-text-foreground",
304
+ disableSelection && "au-pointer-events-none au-opacity-80 au-cursor-not-allowed"
304
305
  ),
305
306
  disabled: disableSelection,
306
307
  children: [
307
308
  "Qty: ",
308
309
  quantity,
309
- /* @__PURE__ */ jsx(ChevronDown, { size: 12 })
310
+ !disableSelection && /* @__PURE__ */ jsx(ChevronDown, { size: 12 })
310
311
  ]
311
312
  }
312
313
  ),
@@ -401,7 +402,7 @@ var PricingDialogButton = ({
401
402
  };
402
403
 
403
404
  // src/libraries/react/components/pricing-table/pricing-table-synced.tsx
404
- import React2 from "react";
405
+ import React from "react";
405
406
  import { createContext, useContext, useState as useState2 } from "react";
406
407
  import { Fragment as Fragment2, jsx as jsx2, jsxs as jsxs2 } from "react/jsx-runtime";
407
408
  function PricingTable({
@@ -638,7 +639,7 @@ var PricingFeatureList = ({
638
639
  )) })
639
640
  ] });
640
641
  };
641
- var PricingCardButton = React2.forwardRef(({ recommended, children, className, onClick, ...props }, ref) => {
642
+ var PricingCardButton = React.forwardRef(({ recommended, children, className, onClick, ...props }, ref) => {
642
643
  const [loading, setLoading] = useState2(false);
643
644
  const handleClick = async (e) => {
644
645
  setLoading(true);
@@ -590,6 +590,9 @@ body {
590
590
  .au-animate-spin {
591
591
  animation: au-spin 1s linear infinite;
592
592
  }
593
+ .au-cursor-not-allowed {
594
+ cursor: not-allowed;
595
+ }
593
596
  .au-cursor-pointer {
594
597
  cursor: pointer;
595
598
  }
@@ -925,6 +928,9 @@ body {
925
928
  .au-opacity-70 {
926
929
  opacity: 0.7;
927
930
  }
931
+ .au-opacity-80 {
932
+ opacity: 0.8;
933
+ }
928
934
  .au-shadow {
929
935
  --tw-shadow: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
930
936
  --tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import React__default from 'react';
3
2
  import { C as CheckoutResult, a as CheckoutParams } from '../../attachTypes-DbuZWzAP.mjs';
3
+ import React__default from 'react';
4
4
  import '../../prodTypes-C4aZSZfO.mjs';
5
5
  import 'zod/v4';
6
6
 
@@ -1,6 +1,6 @@
1
1
  import * as react_jsx_runtime from 'react/jsx-runtime';
2
- import React__default from 'react';
3
2
  import { C as CheckoutResult, a as CheckoutParams } from '../../attachTypes-CKp1KMwX.js';
3
+ import React__default from 'react';
4
4
  import '../../prodTypes-C4aZSZfO.js';
5
5
  import 'zod/v4';
6
6