Skip to content

Commit

Permalink
fix(drawer): fix drawer when changing drawerType (ex: front -> perm…
Browse files Browse the repository at this point in the history
…anent) (#10304)

fixes #10305
  • Loading branch information
SherifMega authored and satya164 committed Nov 27, 2022
1 parent 422cc40 commit a689580
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions packages/drawer/src/views/legacy/Drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -558,7 +558,7 @@ export default class DrawerView extends React.Component<DrawerProps> {
drawerType === 'permanent'
? // Reanimated needs the property to be present, but it results in Browser bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=20574
undefined
[]
: [{ translateX: contentTranslateX }],
},
]}
Expand Down Expand Up @@ -619,7 +619,7 @@ export default class DrawerView extends React.Component<DrawerProps> {
drawerType === 'permanent'
? // Reanimated needs the property to be present, but it results in Browser bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=20574
undefined
[]
: [{ translateX: drawerTranslateX }],
opacity: this.drawerOpacity,
},
Expand Down
4 changes: 2 additions & 2 deletions packages/drawer/src/views/modern/Drawer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -265,7 +265,7 @@ export default function Drawer({
drawerType === 'permanent'
? // Reanimated needs the property to be present, but it results in Browser bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=20574
undefined
[]
: [
{
translateX: drawerType === 'back' ? 0 : translateX.value,
Expand All @@ -280,7 +280,7 @@ export default function Drawer({
drawerType === 'permanent'
? // Reanimated needs the property to be present, but it results in Browser bug
// https://bugs.chromium.org/p/chromium/issues/detail?id=20574
undefined
[]
: [
{
translateX:
Expand Down

0 comments on commit a689580

Please sign in to comment.