Skip to content

Commit 93bbc05

Browse files
committed
fix: resolve build errors — add avatar/org to HanzoUserInfoStore, fix Zod v3/v4 type mismatch, generate d.ts files in @hanzo/ui build
1 parent 1dbda80 commit 93bbc05

File tree

7 files changed

+32
-56
lines changed

7 files changed

+32
-56
lines changed

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -158,7 +158,7 @@
158158
"validator@<13.15.20": ">=13.15.20",
159159
"tar@=7.5.1": ">=7.5.2",
160160
"zod@>4": "4.1.12",
161-
"@hookform/resolvers": "^3.9.0",
161+
"@hookform/resolvers": "3.9.0",
162162
"react": "19.2.0",
163163
"react-dom": "19.2.0",
164164
"@types/react": "19.2.2",

pkg/auth-firebase/service/firebase-auth-service.ts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,21 +27,29 @@ class HanzoUserInfoStore implements HanzoUserInfo {
2727
_email: string = ''
2828
_displayName: string | null = null
2929
_walletAddress: string | null = null
30+
_avatar: string | null = null
31+
_organization: string | null = null
3032

3133
get email(): string { return this._email}
3234
get displayName(): string | null { return this._displayName}
3335
get walletAddress(): string | null { return this._walletAddress}
36+
get avatar(): string | null { return this._avatar}
37+
get organization(): string | null { return this._organization}
3438

3539
clear():void {
3640
this._email = ''
3741
this._displayName = null
3842
this._walletAddress = null
43+
this._avatar = null
44+
this._organization = null
3945
}
4046

4147
set(v: HanzoUserInfoValue):void {
4248
this._email = v.email
4349
this._displayName = v.displayName
4450
this._walletAddress = v.walletAddress
51+
this._avatar = v.avatar ?? null
52+
this._organization = v.organization ?? null
4553
}
4654

4755
get isValid(): boolean {

pkg/commerce/components/cart/cart-panel/promo-code.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ const PromoCode = observer(() => {
5656
}, [cmmc.appliedPromo])
5757

5858
const form = useForm<z.infer<typeof formSchema>>({
59-
resolver: zodResolver(formSchema),
59+
resolver: zodResolver(formSchema as any),
6060
defaultValues: {
6161
code: '',
6262
},

pkg/commerce/components/checkout/payment-step-form/index.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ const PaymentStepForm: React.FC<CheckoutStepComponentProps> = observer(({
3535
}
3636

3737
const contactForm = useForm<z.infer<typeof contactFormSchema>>({
38-
resolver: zodResolver(contactFormSchema),
38+
resolver: zodResolver(contactFormSchema as any),
3939
defaultValues: {
4040
name: auth?.user?.displayName ?? '',
4141
email: auth?.user?.email ?? '',
@@ -111,7 +111,7 @@ const PaymentStepForm: React.FC<CheckoutStepComponentProps> = observer(({
111111
transactionStatus={transactionStatus}
112112
setTransactionStatus={setTransactionStatus}
113113
storePaymentInfo={storePaymentInfo}
114-
contactForm={contactForm}
114+
contactForm={contactForm as any}
115115
/>
116116
</TabsContent>
117117
))}

pkg/commerce/components/checkout/shipping-step-form.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ const ShippingStepForm: React.FC<CheckoutStepComponentProps> = ({
4545
const cmmc = useCommerce()
4646

4747
const shippingForm = useForm<z.infer<typeof shippingFormSchema>>({
48-
resolver: zodResolver(shippingFormSchema),
48+
resolver: zodResolver(shippingFormSchema as any),
4949
defaultValues: {
5050
addressLine1: '',
5151
addressLine2: '',

pkg/ui/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@
4949
"lat": "npm show @hanzo/ui version",
5050
"pub": "npm publish",
5151
"tc": "tsc --project tsconfig.build.json",
52-
"build": "npm run clean && npm run build:minimal",
52+
"build": "npm run clean && npm run build:minimal && npm run tc",
5353
"build:minimal": "tsup --config tsup.config.minimal.ts",
5454
"build:namespaces": "tsup --config tsup.config.namespaces.ts",
5555
"build:full": "tsup --config tsup.config.production.ts",

pnpm-lock.yaml

Lines changed: 18 additions & 50 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)