mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 11:41:20 +08:00
fix(ios): only animate large title if back button is in start slot (#19846)
fixes #19840
This commit is contained in:
@ -27,8 +27,9 @@ const getBackButton = (refEl: any, backDirection: boolean) => {
|
|||||||
const activeHeader = parentHeader && !parentHeader.classList.contains('header-collapse-condense-inactive');
|
const activeHeader = parentHeader && !parentHeader.classList.contains('header-collapse-condense-inactive');
|
||||||
const backButton = buttons.querySelector('ion-back-button');
|
const backButton = buttons.querySelector('ion-back-button');
|
||||||
const buttonsCollapse = buttons.classList.contains('buttons-collapse');
|
const buttonsCollapse = buttons.classList.contains('buttons-collapse');
|
||||||
|
const startSlot = buttons.slot === 'start' || buttons.slot === '';
|
||||||
|
|
||||||
if (backButton !== null && ((buttonsCollapse && activeHeader && backDirection) || !buttonsCollapse)) {
|
if (backButton !== null && startSlot && ((buttonsCollapse && activeHeader && backDirection) || !buttonsCollapse)) {
|
||||||
return backButton;
|
return backButton;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user