ui-material-components icon indicating copy to clipboard operation
ui-material-components copied to clipboard

[Tabs] [Android]: App gets crashed when it is running in background and Phone font size is changed

Open NathanWalker opened this issue 3 years ago • 6 comments

Transfer from core Original reporter @rmn81

Describe the bug App gets crashed when it is running in background and Phone font size is changed. It is happening only when selectedItemColor property is applied on TabStrip. It is happing on android not sure about iOS.

Error: `[ba7898cd]: An uncaught Exception occurred on "main" thread. Calling js method onStart failed TypeError: Cannot read property 'setTextColor' of null

StackTrace: Tabs._setItemColor(file:///data/data/org.nativescript.preview/files/app/tns_modules/@nativescript/core/ui/tabs/tabs.js:608:42) at (file:///data/data/org.nativescript.preview/files/app/tns_modules/@nativescript/core/ui/tabs/tabs.js:477:19) at Tabs.setTabStripItems(file:///data/data/org.nativescript.preview/files/app/tns_modules/@nativescript/core/ui/tabs/tabs.js:474:15) at Tabs.(file:///data/data/org.nativescript.preview/files/app/tns_modules/@nativescript/core/ui/tabs/tabs.js:680:14) at applyAllNativeSetters(file:///data/data/org.nativescript.preview/files/app/tns_modules/@nativescript/core/ui/core/properties/properties.js:1048:28) ............................................................. ............................................................`

Sample project Playground

Additional context ezgif com-gif-maker

NathanWalker avatar Apr 02 '21 23:04 NathanWalker

@NathanWalker i cant reproduce it here on api 29. I did a release with fixes, Could you test and report what version it crashes on?

farfromrefug avatar Apr 05 '21 12:04 farfromrefug

@farfromrefug Tested on API 29. it is still breaking.

Versions: nativescript: NS7(7.0.11) @nativescript/core: 7.1.4 @nativescript/android: 7.0.1

rmn81 avatar Apr 05 '21 14:04 rmn81

@rmn81 what plugin version? That s what i need to know

farfromrefug avatar Apr 05 '21 14:04 farfromrefug

@farfromrefug I am not sure for which plugin you want to know the version. Below is the content of my package.json(you can also check the Playground Sample)

{ "name": "@nativescript/template-hello-world-ts", "main": "app.js", "version": "7.0.6", "author": "NativeScript Team [email protected]", "description": "NativeScript Application", "license": "SEE LICENSE IN ", "publishConfig": { "access": "public" }, "keywords": [ "nativescript", "mobile", "{N}", "template" ], "repository": "", "bugs": { "url": "https://github.com/NativeScript/NativeScript/issues" }, "homepage": "https://github.com/NativeScript/nativescript-app-templates", "dependencies": { "@nativescript/core": "~7.1.0", "@nativescript/theme": "~2.3.0" }, "devDependencies": { "@nativescript/android": "7.0.1", "@nativescript/types": "~7.0.0", "@nativescript/webpack": "~4.0.0", "typescript": "~3.9.0" }, "private": "true", "readme": "NativeScript Application" }

rmn81 avatar Apr 05 '21 15:04 rmn81

@rmn81 i dont understand you dont even use @nativescript-community/ui-material-tabs ? it might.mean that issue already existed in N Tab component ? @NathanWalker I am lost here. (though I fixed the issue in latest release)

farfromrefug avatar Apr 05 '21 17:04 farfromrefug

@NathanWalker this one should be fixed

farfromrefug avatar Aug 19 '21 16:08 farfromrefug