diff --git a/apps/documenteditor/mobile/src/view/edit/EditText.jsx b/apps/documenteditor/mobile/src/view/edit/EditText.jsx index b38ce1be0..7299327b0 100644 --- a/apps/documenteditor/mobile/src/view/edit/EditText.jsx +++ b/apps/documenteditor/mobile/src/view/edit/EditText.jsx @@ -207,11 +207,7 @@ const PageBullets = observer(props => { { - if (bullet.type === -1) { - storeTextSettings.resetBullets(-1); - } else { - storeTextSettings.resetBullets(bullet.type); - } + storeTextSettings.resetBullets(bullet.type); props.onBullet(bullet.type); }}> {bullet.thumb.length < 1 ? @@ -256,11 +252,7 @@ const PageNumbers = observer(props => { { - if (number.type === -1) { - storeTextSettings.resetNumbers(-1); - } else { - storeTextSettings.resetNumbers(number.type); - } + storeTextSettings.resetNumbers(number.type); props.onNumber(number.type); }}> {number.thumb.length < 1 ? diff --git a/apps/presentationeditor/mobile/src/view/edit/EditText.jsx b/apps/presentationeditor/mobile/src/view/edit/EditText.jsx index e6bcb068c..8fae5157f 100644 --- a/apps/presentationeditor/mobile/src/view/edit/EditText.jsx +++ b/apps/presentationeditor/mobile/src/view/edit/EditText.jsx @@ -490,7 +490,7 @@ const PageAdditionalFormatting = props => { ) }; -const PageBullets = props => { +const PageBullets = observer(props => { const { t } = useTranslation(); const _t = t('View.Edit', {returnObjects: true}); const bulletArrays = [ @@ -525,11 +525,8 @@ const PageBullets = props => { { - if (bullet.type === -1) { - storeTextSettings.resetBullets(-1); - } - props.onBullet(bullet.type) - props.f7router.back(); + storeTextSettings.resetBullets(bullet.type); + props.onBullet(bullet.type); }}> {bullet.thumb.length < 1 ? @@ -543,9 +540,9 @@ const PageBullets = props => { ))} ) -}; +}); -const PageNumbers = props => { +const PageNumbers = observer(props => { const { t } = useTranslation(); const _t = t('View.Edit', {returnObjects: true}); const numberArrays = [ @@ -573,7 +570,7 @@ const PageNumbers = props => { return null; } - return( + return ( {numberArrays.map((numbers, index) => ( @@ -581,11 +578,8 @@ const PageNumbers = props => { { - if (number.type === -1) { - storeTextSettings.resetNumbers(-1); - } - props.onNumber(number.type) - props.f7router.back(); + storeTextSettings.resetNumbers(number.type); + props.onNumber(number.type); }}> {number.thumb.length < 1 ? @@ -599,7 +593,7 @@ const PageNumbers = props => { ))} ) -}; +}); const PageBulletsAndNumbers = props => { const { t } = useTranslation();