Skip to content

Commit b796f35

Browse files
author
OleS
committed
Fix: Virtusize button state when loading a new product
1 parent 293ee26 commit b796f35

File tree

3 files changed

+20
-0
lines changed

3 files changed

+20
-0
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,6 @@
11
### Changes
22
- Fix: issue with no size found text
3+
- Fix: Virtusize button state when loading a new product
34

45
### 2.12.13
56
- Fix: External Link redirect issue

virtusize/src/main/java/com/virtusize/android/ui/VirtusizeInPageMini.kt

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,21 @@ class VirtusizeInPageMini
114114
imageLoader.enqueue(request)
115115
}
116116

117+
/**
118+
* @see VirtusizeView.initialSetup
119+
*/
120+
override fun initialSetup(
121+
product: VirtusizeProduct,
122+
params: VirtusizeParams,
123+
messageHandler: VirtusizeMessageHandler,
124+
) {
125+
super.initialSetup(product, params, messageHandler)
126+
127+
// Reset root visibility when setting up a new product
128+
// This ensures the view shows properly after switching from an invalid product
129+
binding.root.visibility = View.VISIBLE
130+
}
131+
117132
/**
118133
* @see VirtusizeView.setProductWithProductCheckData
119134
* @throws VirtusizeErrorType.NullProduct error

virtusize/src/main/java/com/virtusize/android/ui/VirtusizeInPageStandard.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -218,6 +218,10 @@ class VirtusizeInPageStandard
218218
})
219219
}
220220
binding.privacyPolicyText.visibility = showPrivacyPolicy()
221+
222+
// Reset root visibility when setting up a new product
223+
// This ensures the view shows properly after switching from an invalid product
224+
binding.root.visibility = View.VISIBLE
221225
}
222226

223227
/**

0 commit comments

Comments
 (0)