我正在尝试在闪屏中的特定位置添加2张或更多图片,例如1张图片是我的徽标,它将位于屏幕的中心,而其他图片是图案设计,将在屏幕底部以全宽显示,背景将是纯色。我已经用谷歌搜索,但是我只得到通用的config.xml
文件样式。如下所示:
<platform name="android">
<icon qualifier="ldpi" src="res/icons/android/drawable-ldpi-icon.png" />
<icon qualifier="mdpi" src="res/icons/android/drawable-mdpi-icon.png" />
<icon qualifier="hdpi" src="res/icons/android/drawable-hdpi-icon.png" />
<icon qualifier="xhdpi" src="res/icons/android/drawable-xhdpi-icon.png" />
<icon qualifier="xxhdpi" src="res/icons/android/drawable-xxhdpi-icon.png" />
<icon qualifier="xxxhdpi" src="res/icons/android/drawable-xxxhdpi-icon.png" />
<splash qualifier="land-ldpi" src="res/screens/android/drawable-land-ldpi-screen.png" />
<splash qualifier="land-mdpi" src="res/screens/android/drawable-land-mdpi-screen.png" />
<splash qualifier="land-hdpi" src="res/screens/android/drawable-land-hdpi-screen.png" />
<splash qualifier="land-xhdpi" src="res/screens/android/drawable-land-xhdpi-screen.png" />
<splash qualifier="land-xxhdpi" src="res/screens/android/drawable-land-xxhdpi-screen.png" />
<splash qualifier="land-xxxhdpi" src="res/screens/android/drawable-land-xxxhdpi-screen.png" />
<splash qualifier="port-ldpi" src="res/screens/android/drawable-port-ldpi-screen.png" />
<splash qualifier="port-mdpi" src="res/screens/android/drawable-port-mdpi-screen.png" />
<splash qualifier="port-hdpi" src="res/screens/android/drawable-port-hdpi-screen.png" />
<splash qualifier="port-xhdpi" src="res/screens/android/drawable-port-xhdpi-screen.png" />
<splash qualifier="port-xxhdpi" src="res/screens/android/drawable-port-xxhdpi-screen.png" />
<splash qualifier="port-xxxhdpi" src="res/screens/android/drawable-port-xxxhdpi-screen.png" />
</platform>
<platform name="ios">
<icon height="57" platform="ios" src="res/icons/ios/icon.png" width="57" />
<icon height="114" platform="ios" src="res/icons/ios/icon@2x.png" width="114" />
<icon height="40" platform="ios" src="res/icons/ios/icon-40.png" width="40" />
<icon height="80" platform="ios" src="res/icons/ios/icon-40@2x.png" width="80" />
<icon height="50" platform="ios" src="res/icons/ios/icon-50.png" width="50" />
<icon height="100" platform="ios" src="res/icons/ios/icon-50@2x.png" width="100" />
<icon height="60" platform="ios" src="res/icons/ios/icon-60.png" width="60" />
<icon height="120" platform="ios" src="res/icons/ios/icon-60@2x.png" width="120" />
<icon height="180" platform="ios" src="res/icons/ios/icon-60@3x.png" width="180" />
<icon height="72" platform="ios" src="res/icons/ios/icon-72.png" width="72" />
<icon height="144" platform="ios" src="res/icons/ios/icon-72@2x.png" width="144" />
<icon height="76" platform="ios" src="res/icons/ios/icon-76.png" width="76" />
<icon height="152" platform="ios" src="res/icons/ios/icon-76@2x.png" width="152" />
<icon height="29" platform="ios" src="res/icons/ios/icon-small.png" width="29" />
<icon height="58" platform="ios" src="res/icons/ios/icon-small@2x.png" width="58" />
<icon height="87" platform="ios" src="res/icons/ios/icon-small@3x.png" width="87" />
<splash height="1136" platform="ios" src="res/screens/ios/Default-568h@2x~iphone.png" width="640" />
<splash height="1334" platform="ios" src="res/screens/ios/Default-667h.png" width="750" />
<splash height="2208" platform="ios" src="res/screens/ios/Default-736h.png" width="1242" />
<splash height="1242" platform="ios" src="res/screens/ios/Default-Landscape-736h.png" width="2208" />
<splash height="1536" platform="ios" src="res/screens/ios/Default-Landscape@2x~ipad.png" width="2048" />
<splash height="768" platform="ios" src="res/screens/ios/Default-Landscape~ipad.png" width="1024" />
<splash height="2048" platform="ios" src="res/screens/ios/Default-Portrait@2x~ipad.png" width="1536" />
<splash height="1024" platform="ios" src="res/screens/ios/Default-Portrait~ipad.png" width="768" />
<splash height="960" platform="ios" src="res/screens/ios/Default@2x~iphone.png" width="640" />
<splash height="480" platform="ios" src="res/screens/ios/Default~iphone.png" width="320" />
</platform>
有什么适当的方法可以完成它吗?
答案 0 :(得分:0)
启动画面基本上是不可编程的,甚至不支持本地化之类的基本功能。解决该问题的一种可能的方法是在index.html
标签内的<ion-app>
文件中为“启动画面”添加HTML。
<ion-app>
<div class="appload">
<div class="loadingtext">
<div class="primary-text">
</div>
<div class="secondary-text">
</div>
Loading.....
</div>
</div>
</ion-app>
我在几个项目中都使用了上述内容,我注意到的一个具体问题是, CSS样式仅在使用index.html 本身编写时才有效。