Merge pull request #1665 from ONLYOFFICE/feature/fix-bugs

Feature/fix bugs
This commit is contained in:
maxkadushkin 2022-03-30 16:59:18 +03:00 committed by GitHub
commit 3d419cd23a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 75 additions and 74 deletions

View file

@ -124,12 +124,14 @@
} }
} }
} }
// Bullets, numbers and multilevels // Bullets, numbers and multilevels
.bullets,
.numbers, .bullets,
.multilevels { .numbers,
.list{ .multilevels {
margin: 5px; .list {
margin: 0;
ul { ul {
background: none; background: none;
&:before, &:after { &:before, &:after {
@ -138,8 +140,7 @@
display: flex; display: flex;
justify-content: space-around; justify-content: space-around;
width: 100%; width: 100%;
margin-top: 10px; padding: 5px;
padding: 0 5px;
li { li {
width: 70px; width: 70px;
@ -195,6 +196,14 @@
} }
} }
.popover .list + .list {
margin-top: 0;
}
.popover .list:first-child li:first-child, .popover .list:first-child li:first-child a, .popover .list:first-child li:first-child > label, .popover .list:last-child li:last-child, .popover .list:last-child li:last-child a, .popover .list:last-child li:last-child > label {
border-radius: 0;
}
.shapes { .shapes {
li { li {
width: 70px; width: 70px;

View file

@ -227,7 +227,7 @@ class ContextMenu extends ContextMenuController {
} else { } else {
const { t } = this.props; const { t } = this.props;
const _t = t("ContextMenu", {returnObjects: true}); const _t = t("ContextMenu", {returnObjects: true});
const { canViewComments, canCoAuthoring, canComments } = this.props; const { canViewComments, canCoAuthoring, canComments, dataDoc } = this.props;
const api = Common.EditorApi.get(); const api = Common.EditorApi.get();
const stack = api.getSelectedElements(); const stack = api.getSelectedElements();

View file

@ -239,3 +239,9 @@
color: @brandColor; color: @brandColor;
} }
} }
.calendar-sheet {
.calendar-month-picker, .calendar-year-picker {
border-top: 1px solid var(--background-menu-divider);
}
}

View file

@ -207,11 +207,7 @@ const PageBullets = observer(props => {
<ListItem key={'bullet-' + bullet.type} data-type={bullet.type} className={(bullet.type === typeBullets) && <ListItem key={'bullet-' + bullet.type} data-type={bullet.type} className={(bullet.type === typeBullets) &&
(storeTextSettings.listType === 0 || storeTextSettings.listType === -1) ? 'active' : ''} (storeTextSettings.listType === 0 || storeTextSettings.listType === -1) ? 'active' : ''}
onClick={() => { onClick={() => {
if (bullet.type === -1) {
storeTextSettings.resetBullets(-1);
} else {
storeTextSettings.resetBullets(bullet.type); storeTextSettings.resetBullets(bullet.type);
}
props.onBullet(bullet.type); props.onBullet(bullet.type);
}}> }}>
{bullet.thumb.length < 1 ? {bullet.thumb.length < 1 ?
@ -256,11 +252,7 @@ const PageNumbers = observer(props => {
<ListItem key={'number-' + number.type} data-type={number.type} className={(number.type === typeNumbers) && <ListItem key={'number-' + number.type} data-type={number.type} className={(number.type === typeNumbers) &&
(storeTextSettings.listType === 1 || storeTextSettings.listType === -1) ? 'active' : ''} (storeTextSettings.listType === 1 || storeTextSettings.listType === -1) ? 'active' : ''}
onClick={() => { onClick={() => {
if (number.type === -1) {
storeTextSettings.resetNumbers(-1);
} else {
storeTextSettings.resetNumbers(number.type); storeTextSettings.resetNumbers(number.type);
}
props.onNumber(number.type); props.onNumber(number.type);
}}> }}>
{number.thumb.length < 1 ? {number.thumb.length < 1 ?

View file

@ -490,7 +490,7 @@ const PageAdditionalFormatting = props => {
) )
}; };
const PageBullets = props => { const PageBullets = observer(props => {
const { t } = useTranslation(); const { t } = useTranslation();
const _t = t('View.Edit', {returnObjects: true}); const _t = t('View.Edit', {returnObjects: true});
const bulletArrays = [ const bulletArrays = [
@ -525,11 +525,8 @@ const PageBullets = props => {
<ListItem key={'bullet-' + bullet.type} data-type={bullet.type} className={(bullet.type === typeBullets) && <ListItem key={'bullet-' + bullet.type} data-type={bullet.type} className={(bullet.type === typeBullets) &&
(storeTextSettings.listType === 0 || storeTextSettings.listType === -1) ? 'active' : ''} (storeTextSettings.listType === 0 || storeTextSettings.listType === -1) ? 'active' : ''}
onClick={() => { onClick={() => {
if (bullet.type === -1) { storeTextSettings.resetBullets(bullet.type);
storeTextSettings.resetBullets(-1); props.onBullet(bullet.type);
}
props.onBullet(bullet.type)
props.f7router.back();
}}> }}>
{bullet.thumb.length < 1 ? {bullet.thumb.length < 1 ?
<Icon className="thumb" style={{position: 'relative'}}> <Icon className="thumb" style={{position: 'relative'}}>
@ -543,9 +540,9 @@ const PageBullets = props => {
))} ))}
</View> </View>
) )
}; });
const PageNumbers = props => { const PageNumbers = observer(props => {
const { t } = useTranslation(); const { t } = useTranslation();
const _t = t('View.Edit', {returnObjects: true}); const _t = t('View.Edit', {returnObjects: true});
const numberArrays = [ const numberArrays = [
@ -573,7 +570,7 @@ const PageNumbers = props => {
return null; return null;
} }
return( return (
<View className='numbers dataview'> <View className='numbers dataview'>
{numberArrays.map((numbers, index) => ( {numberArrays.map((numbers, index) => (
<List className="row" style={{listStyle: 'none'}} key={'numbers-' + index}> <List className="row" style={{listStyle: 'none'}} key={'numbers-' + index}>
@ -581,11 +578,8 @@ const PageNumbers = props => {
<ListItem key={'number-' + number.type} data-type={number.type} className={(number.type === typeNumbers) && <ListItem key={'number-' + number.type} data-type={number.type} className={(number.type === typeNumbers) &&
(storeTextSettings.listType === 1 || storeTextSettings.listType === -1) ? 'active' : ''} (storeTextSettings.listType === 1 || storeTextSettings.listType === -1) ? 'active' : ''}
onClick={() => { onClick={() => {
if (number.type === -1) { storeTextSettings.resetNumbers(number.type);
storeTextSettings.resetNumbers(-1); props.onNumber(number.type);
}
props.onNumber(number.type)
props.f7router.back();
}}> }}>
{number.thumb.length < 1 ? {number.thumb.length < 1 ?
<Icon className="thumb" style={{position: 'relative'}}> <Icon className="thumb" style={{position: 'relative'}}>
@ -599,7 +593,7 @@ const PageNumbers = props => {
))} ))}
</View> </View>
) )
}; });
const PageBulletsAndNumbers = props => { const PageBulletsAndNumbers = props => {
const { t } = useTranslation(); const { t } = useTranslation();