@coinbase/cds-mobile 8.75.1 → 8.75.3
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/CHANGELOG.md
CHANGED
|
@@ -8,6 +8,16 @@ All notable changes to this project will be documented in this file.
|
|
|
8
8
|
|
|
9
9
|
<!-- template-start -->
|
|
10
10
|
|
|
11
|
+
## 8.75.3 (5/22/2026 PST)
|
|
12
|
+
|
|
13
|
+
#### 🐞 Fixes
|
|
14
|
+
|
|
15
|
+
- Fix: update tray drag position live on iOS during swipe. [[#719](https://github.com/coinbase/cds/pull/719)]
|
|
16
|
+
|
|
17
|
+
## 8.75.2 ((5/19/2026, 01:13 PM PST))
|
|
18
|
+
|
|
19
|
+
This is an artificial version bump with no new change.
|
|
20
|
+
|
|
11
21
|
## 8.75.1 ((5/19/2026, 07:30 AM PST))
|
|
12
22
|
|
|
13
23
|
This is an artificial version bump with no new change.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useDrawerPanResponder.d.ts","sourceRoot":"","sources":["../../../src/overlays/drawer/useDrawerPanResponder.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAmD,MAAM,cAAc,CAAC;AAC9F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAgB7D,KAAK,2BAA2B,GAAG;IACjC,eAAe,EAAE,QAAQ,CAAC,KAAK,CAAC;IAChC,eAAe,EAAE,QAAQ,CAAC,kBAAkB,CAAC;IAC7C,GAAG,EAAE,gBAAgB,CAAC;IACtB,iCAAiC,EAAE,OAAO,CAAC;IAC3C,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,kBAAkB,EAAE,MAAM,IAAI,CAAC;IAC/B,gBAAgB,EAAE,QAAQ,CAAC,KAAK,CAAC;IACjC,8BAA8B,EAAE,MAAM,CAAC;CACxC,CAAC;AASF,eAAO,MAAM,qBAAqB,GAAI,6JASnC,2BAA2B,
|
|
1
|
+
{"version":3,"file":"useDrawerPanResponder.d.ts","sourceRoot":"","sources":["../../../src/overlays/drawer/useDrawerPanResponder.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,QAAQ,EAAmD,MAAM,cAAc,CAAC;AAC9F,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAgB7D,KAAK,2BAA2B,GAAG;IACjC,eAAe,EAAE,QAAQ,CAAC,KAAK,CAAC;IAChC,eAAe,EAAE,QAAQ,CAAC,kBAAkB,CAAC;IAC7C,GAAG,EAAE,gBAAgB,CAAC;IACtB,iCAAiC,EAAE,OAAO,CAAC;IAC3C,MAAM,CAAC,EAAE,MAAM,IAAI,CAAC;IACpB,kBAAkB,EAAE,MAAM,IAAI,CAAC;IAC/B,gBAAgB,EAAE,QAAQ,CAAC,KAAK,CAAC;IACjC,8BAA8B,EAAE,MAAM,CAAC;CACxC,CAAC;AASF,eAAO,MAAM,qBAAqB,GAAI,6JASnC,2BAA2B,gDA4N7B,CAAC"}
|
|
@@ -127,11 +127,20 @@ export const useDrawerPanResponder = _ref => {
|
|
|
127
127
|
}
|
|
128
128
|
return false;
|
|
129
129
|
}, [isTryingToDismiss, parseGestureState, isFlingToDismiss, isSwipeToDismiss]);
|
|
130
|
+
const initializeDragAnimation = useCallback(() => {
|
|
131
|
+
// On iOS, setOffset during pan move does not flush to native; capture the current
|
|
132
|
+
// position as offset via extractOffset() so setValue in onPanResponderMove updates the UI.
|
|
133
|
+
drawerAnimation.stopAnimation();
|
|
134
|
+
opacityAnimation.stopAnimation();
|
|
135
|
+
drawerAnimation.extractOffset();
|
|
136
|
+
opacityAnimation.extractOffset();
|
|
137
|
+
}, [drawerAnimation, opacityAnimation]);
|
|
130
138
|
const panGestureHandlers = useMemo(() => {
|
|
131
139
|
return PanResponder.create({
|
|
132
140
|
onStartShouldSetPanResponder: () => true,
|
|
133
141
|
onMoveShouldSetPanResponder: shouldCaptureGestures,
|
|
134
142
|
onMoveShouldSetPanResponderCapture: shouldCaptureGestures,
|
|
143
|
+
onPanResponderGrant: initializeDragAnimation,
|
|
135
144
|
onPanResponderMove: (_, gestureState) => {
|
|
136
145
|
const {
|
|
137
146
|
isDragging,
|
|
@@ -148,20 +157,20 @@ export const useDrawerPanResponder = _ref => {
|
|
|
148
157
|
outputRange: [0, 0.1],
|
|
149
158
|
clamp: true
|
|
150
159
|
});
|
|
151
|
-
drawerAnimation.
|
|
160
|
+
drawerAnimation.setValue(calculateDragOffset(normalizedDistance));
|
|
152
161
|
} else {
|
|
153
162
|
const normalizedDrawerTransition = modulate(distance, {
|
|
154
163
|
inputRange: [0, isHorizontalDrawer ? horizontalDrawerMaxPanDistance : verticalDrawerMaxPanDistance],
|
|
155
164
|
outputRange: [0, normalizeDrawerPanDistanceMultiplier],
|
|
156
165
|
clamp: false
|
|
157
166
|
});
|
|
158
|
-
drawerAnimation.
|
|
167
|
+
drawerAnimation.setValue(normalizedDrawerTransition);
|
|
159
168
|
const normalizedOpacityTransition = modulate(distance, {
|
|
160
169
|
inputRange: [0, isHorizontalDrawer ? horizontalDrawerMaxPanDistance : verticalDrawerMaxPanDistance],
|
|
161
170
|
outputRange: [0, 1],
|
|
162
171
|
clamp: false
|
|
163
172
|
});
|
|
164
|
-
opacityAnimation.
|
|
173
|
+
opacityAnimation.setValue(normalizedOpacityTransition);
|
|
165
174
|
}
|
|
166
175
|
}
|
|
167
176
|
},
|
|
@@ -176,6 +185,6 @@ export const useDrawerPanResponder = _ref => {
|
|
|
176
185
|
}
|
|
177
186
|
}
|
|
178
187
|
});
|
|
179
|
-
}, [drawerAnimation, animateSnapBack, parseGestureState, shouldCaptureGestures, shouldDismiss, drawerWidth, drawerHeight, pin, isHorizontalDrawer, onBlur, handleSwipeToClose, opacityAnimation]);
|
|
188
|
+
}, [drawerAnimation, animateSnapBack, initializeDragAnimation, parseGestureState, shouldCaptureGestures, shouldDismiss, drawerWidth, drawerHeight, pin, isHorizontalDrawer, onBlur, handleSwipeToClose, opacityAnimation]);
|
|
180
189
|
return panGestureHandlers;
|
|
181
190
|
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@coinbase/cds-mobile",
|
|
3
|
-
"version": "8.75.
|
|
3
|
+
"version": "8.75.3",
|
|
4
4
|
"description": "Coinbase Design System - Mobile",
|
|
5
5
|
"repository": {
|
|
6
6
|
"type": "git",
|
|
@@ -196,7 +196,7 @@
|
|
|
196
196
|
"react-native-svg": "^14.1.0"
|
|
197
197
|
},
|
|
198
198
|
"dependencies": {
|
|
199
|
-
"@coinbase/cds-common": "^8.75.
|
|
199
|
+
"@coinbase/cds-common": "^8.75.3",
|
|
200
200
|
"@coinbase/cds-icons": "^5.16.0",
|
|
201
201
|
"@coinbase/cds-illustrations": "^4.40.1",
|
|
202
202
|
"@coinbase/cds-lottie-files": "^3.3.4",
|