iOS LaunchScreen light and dark mode #26133
-
Hi, <ImageAsset Include="Assets.xcassets\LaunchIcon.imageset\Contents.json">
<Visible>false</Visible>
</ImageAsset> and my LaunchScreen.storyboard which references the LaunchIcon imageset. I also set UILaunchStoryboardName in Info.plist. |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
After two days of try and error it finally works. The trick was to set the link property in the csproj file. Here is what i have done. <ItemGroup Condition="$([MSBuild]::GetTargetPlatformIdentifier('$(TargetFramework)')) == 'ios'">
<ImageAsset Include="Platforms\iOS\Splash\LaunchIcon.imageset\Contents.json" Link="Assets.xcassets\LaunchIcon.imageset\Contents.json" />
<ImageAsset Include="Platforms\iOS\Splash\LaunchIcon.imageset\Logo_dark.pdf" Link="Assets.xcassets\LaunchIcon.imageset\Logo_dark.pdf" />
<ImageAsset Include="Platforms\iOS\Splash\LaunchIcon.imageset\Logo_light.pdf" Link="Assets.xcassets\LaunchIcon.imageset\Logo_light.pdf" />
<InterfaceDefinition Include="Platforms\iOS\Splash\LaunchScreen.storyboard" Link="LaunchScreen.storyboard" />
</ItemGroup> Also set in info.plist <key>UILaunchStoryboardName</key>
<string>LaunchScreen.storyboard</string> |
Beta Was this translation helpful? Give feedback.
After two days of try and error it finally works. The trick was to set the link property in the csproj file. Here is what i have done.