NativeScript / NativeScript/nativescript-cli

tns resources generate splashes are the wrong size

未关闭
#5,358 0 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
JavaScript
星标
1.1k
派生
204
平均合并
1 天 9 小时
30 天内合并 PR
8

描述

Environment

  Getting NativeScript components versions information...
✔ Component nativescript has 6.8.0 version and is up to date.
✔ Component tns-core-modules has 6.5.15 version and is up to date.
⚠ Update available for component tns-android. Your current version is 6.5.0 and the latest available version is 6.5.3.
⚠ Update available for component tns-ios. Your current version is 6.5.0 and the latest available version is 6.5.2.

Describe the bug

When running tns resources generate splashes image.png the android splash screens are very small.
I tried with different sizes of input image, all corresponding to a scale up of xxxhdpi. Still, very small. Tried with a square image instead of 1920x1080, same result.

To Reproduce

  • Create an image, 1920x1080, or anything bigger/smaller
  • tns resources generate splashes image.png
  • Go to the Android's xxxhdpi resources folder.
  • The image is like 640px

Expected behavior
Images the right size, but I'm really not sure what it's expecting as an input. Bigger files with special names for IOS?
I ended up using http://images.nativescript.rocks/

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先使用报告的图像尺寸重现 tns resources generate splashes image.png,并检查生成的 Android xxxhdpi 资源。跟踪 splash 生成的 CLI 入口点,以确定输出尺寸的计算方式。当生成的 splash 图像具有受支持平台所预期的尺寸时,即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
android, ios, javascript
领域
cli, mobile
Issue 类型
缺陷
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
42/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。