我有问题的GoogleMaps和新的‘滑动关闭’模式。我的问题是,由_gmaps_cdv_附加到body的类GoogleMaps正在将背景色更改为白色。效果看起来很奇怪也很糟糕。
我已经尝试了几乎所有的东西,…
一旦加载模式,
有小费吗?这是个虫子吗?
谢谢
发布于 2020-04-13 01:49:44
我搞定了这件事。解决办法很简单。可以在Environment类的GoogleMaps上设置背景色。
确保在组件上导入了Environment,并执行以下操作:
// If you're following the documentation, there should be more things imported here, because I'm focusing on the Environment, I will only use this one.
import { Environment } from '@ionic-native/google-maps/ngx';
ngOninit() {
Environment.setBackgroundColor('black'); // Or whatever color you want.
}就这样!以下是参考的文档链接:
https://github.com/ionic-team/ionic-native-google-maps/blob/master/documents/environment/README.md
https://stackoverflow.com/questions/61150133
复制相似问题