|
@@ -1,3 +1,4 @@
|
|
|
+import Taro from '@tarojs/taro'
|
|
|
import { PropsWithChildren } from 'react'
|
|
|
|
|
|
export const noop = () => {}
|
|
@@ -12,6 +13,13 @@ export function wrapProps(props: PropsWithChildren<CustomPropsType>) {
|
|
|
onClose = noop
|
|
|
} = props
|
|
|
|
|
|
+
|
|
|
+
|
|
|
+ if (!width) {
|
|
|
+ const windowInfo = Taro.getWindowInfo()
|
|
|
+ width = windowInfo?.windowWidth
|
|
|
+ }
|
|
|
+
|
|
|
return {
|
|
|
adpId,
|
|
|
width,
|