mirror of
https://github.com/NativeScript/NativeScript.git
synced 2025-08-16 03:31:45 +08:00
Release to master (#8382)
* fix the crash * chore: update MaterialComponents pod (#8176) * chore: update MaterialComponents pod * chore: remove copy of pod file in build script * chore: cut the 6.3.0 release (#8174) * hore: cut the 6.3.1 release * fix: handle fake attach after FragMgr is destroyed (#8200) * fix: check is disposed fragment is in the FragmentManager (#8201) * release: cut the 6.3.2 release * release: cut the 6.4.0 release * chore(build): always use local typescript * fix: flipLeft and flipRight on Android (#8307) * fix(android): tap-trip-item title disappearing * fix(andoid): crash when setting font on tab-item with no image * fix(build): Add platforms/android to NPM package (#8312) Co-authored-by: Dimitar Topuzov <dtopuzov@gmail.com> Co-authored-by: Alexander Vakrilov <alexander.vakrilov@gmail.com> * release: cut the 6.4.1 release * chore: bump tns-core-modules-widgets version (#8352) Co-authored-by: hamidbsd <50081218+hamidbsd@users.noreply.github.com> Co-authored-by: Alexander Vakrilov <alexander.vakrilov@gmail.com> Co-authored-by: Dimitar Topuzov <dtopuzov@gmail.com> Co-authored-by: Nick Iliev <nikolay.iliev@telerik.com> Co-authored-by: Martin Bektchiev <martin.bektchiev@progress.com> Co-authored-by: Rosen Vladimirov <rosen-vladimirov@users.noreply.github.com>
This commit is contained in:
@ -13,6 +13,7 @@
|
||||
"**/*.d.ts",
|
||||
"**/*.js",
|
||||
"**/platforms/ios/**",
|
||||
"**/platforms/android/**",
|
||||
"**/package.json",
|
||||
"!org.nativescript.widgets.d.ts"
|
||||
],
|
||||
@ -59,4 +60,4 @@
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -391,7 +391,7 @@ export class BottomNavigation extends TabNavigationBase {
|
||||
if (this._manager && this._manager.isDestroyed()) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
this._attachedToWindow = true;
|
||||
this.changeTab(this.selectedIndex);
|
||||
}
|
||||
@ -614,6 +614,9 @@ export class BottomNavigation extends TabNavigationBase {
|
||||
|
||||
private getIcon(tabStripItem: TabStripItem): android.graphics.drawable.BitmapDrawable {
|
||||
const iconSource = tabStripItem.image && tabStripItem.image.src;
|
||||
if (!iconSource) {
|
||||
return null;
|
||||
}
|
||||
|
||||
let is: ImageSource;
|
||||
if (isFontIconURI(iconSource)) {
|
||||
@ -705,7 +708,10 @@ export class BottomNavigation extends TabNavigationBase {
|
||||
}
|
||||
|
||||
public setTabBarItemFontInternal(tabStripItem: TabStripItem, value: Font): void {
|
||||
tabStripItem.nativeViewProtected.setTextSize(value.fontSize);
|
||||
if (value.fontSize) {
|
||||
tabStripItem.nativeViewProtected.setTextSize(value.fontSize);
|
||||
}
|
||||
|
||||
tabStripItem.nativeViewProtected.setTypeface(value.getAndroidTypeface());
|
||||
}
|
||||
|
||||
|
@ -145,7 +145,7 @@ export function _setAndroidFragmentTransitions(
|
||||
if (currentFragmentNeedsDifferentAnimation) {
|
||||
setupCurrentFragmentExplodeTransition(navigationTransition, currentEntry);
|
||||
}
|
||||
} else if (name === "flip") {
|
||||
} else if (name.indexOf("flip") === 0) {
|
||||
const direction = name.substr("flip".length) || "right"; //Extract the direction from the string
|
||||
const flipTransition = new FlipTransition(direction, navigationTransition.duration, navigationTransition.curve);
|
||||
|
||||
|
@ -127,7 +127,7 @@ export class TabStripItem extends View implements TabStripItemDefinition, AddChi
|
||||
const parent = <TabStrip>this.parent;
|
||||
const tabStripParent = parent && <TabNavigationBase>parent.parent;
|
||||
|
||||
return tabStripParent && (<any>tabStripParent).setTabBarIconColor(this, args.value);
|
||||
return tabStripParent && tabStripParent.setTabBarIconColor(this, args.value);
|
||||
});
|
||||
this.image.style.on("colorChange", this._imageColorHandler);
|
||||
|
||||
@ -135,7 +135,7 @@ export class TabStripItem extends View implements TabStripItemDefinition, AddChi
|
||||
const parent = <TabStrip>this.parent;
|
||||
const tabStripParent = parent && <TabNavigationBase>parent.parent;
|
||||
|
||||
return tabStripParent && (<any>tabStripParent).setTabBarIconColor(this, args.value);
|
||||
return tabStripParent && tabStripParent.setTabBarIconColor(this, args.value);
|
||||
});
|
||||
this.image.style.on("fontInternalChange", this._imageFontHandler);
|
||||
|
||||
@ -143,7 +143,7 @@ export class TabStripItem extends View implements TabStripItemDefinition, AddChi
|
||||
const parent = <TabStrip>this.parent;
|
||||
const tabStripParent = parent && <TabNavigationBase>parent.parent;
|
||||
|
||||
return tabStripParent && (<any>tabStripParent).setTabBarIconColor(this, args.value);
|
||||
return tabStripParent && tabStripParent.setTabBarIconColor(this, args.value);
|
||||
});
|
||||
this.image.on("srcChange", this._imageSrcHandler);
|
||||
}
|
||||
|
@ -689,6 +689,9 @@ export class Tabs extends TabsBase {
|
||||
|
||||
private getIcon(tabStripItem: TabStripItem): android.graphics.drawable.BitmapDrawable {
|
||||
const iconSource = tabStripItem.image && tabStripItem.image.src;
|
||||
if (!iconSource) {
|
||||
return null;
|
||||
}
|
||||
|
||||
let is: ImageSource;
|
||||
if (isFontIconURI(iconSource)) {
|
||||
@ -814,12 +817,14 @@ export class Tabs extends TabsBase {
|
||||
const tabBarItem = this._tabsBar.getViewForItemAt(index);
|
||||
const imgView = <android.widget.ImageView>tabBarItem.getChildAt(0);
|
||||
const drawable = this.getIcon(tabStripItem);
|
||||
|
||||
|
||||
imgView.setImageDrawable(drawable);
|
||||
}
|
||||
|
||||
public setTabBarItemFontInternal(tabStripItem: TabStripItem, value: Font): void {
|
||||
tabStripItem.nativeViewProtected.setTextSize(value.fontSize);
|
||||
if (value.fontSize) {
|
||||
tabStripItem.nativeViewProtected.setTextSize(value.fontSize);
|
||||
}
|
||||
tabStripItem.nativeViewProtected.setTypeface(value.getAndroidTypeface());
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user