Merge pull request #1815 from ONLYOFFICE/feature/fix-bug-react
Feature/fix bug react
This commit is contained in:
commit
361161478b
|
@ -181,6 +181,7 @@
|
||||||
margin-top: 21px;
|
margin-top: 21px;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
box-shadow: 0 0 0 1px rgba(0, 0, 0, .15) inset;
|
box-shadow: 0 0 0 1px rgba(0, 0, 0, .15) inset;
|
||||||
|
background: @fill-white;
|
||||||
}
|
}
|
||||||
.item-after {
|
.item-after {
|
||||||
.color-preview {
|
.color-preview {
|
||||||
|
|
|
@ -196,7 +196,7 @@ const EditParagraph = props => {
|
||||||
|
|
||||||
const paragraph = props.storeFocusObjects.paragraphObject;
|
const paragraph = props.storeFocusObjects.paragraphObject;
|
||||||
const curBackColor = storeParagraphSettings.backColor ? storeParagraphSettings.backColor : storeParagraphSettings.getBackgroundColor(paragraph);
|
const curBackColor = storeParagraphSettings.backColor ? storeParagraphSettings.backColor : storeParagraphSettings.getBackgroundColor(paragraph);
|
||||||
const background = curBackColor !== 'transparent' ? `#${(typeof curBackColor === "object" ? curBackColor.color : curBackColor)}` : curBackColor;
|
const background = curBackColor !== 'transparent' ? `#${(typeof curBackColor === "object" ? curBackColor.color : curBackColor)}` : '';
|
||||||
const activeStyle = Device.android ? 'link no-active-state' : 'no-active-state';
|
const activeStyle = Device.android ? 'link no-active-state' : 'no-active-state';
|
||||||
|
|
||||||
return (
|
return (
|
||||||
|
|
|
@ -243,25 +243,18 @@ const PageNumbers = observer( props => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<View className='numbers dataview'>
|
<View className='numbers dataview'>
|
||||||
{numberArrays.map((numbers, index) => (
|
<List className="row" style={{listStyle: 'none'}}>
|
||||||
<List className="row" style={{listStyle: 'none'}} key={'numbers-' + index}>
|
{numberArrays.map( number => (
|
||||||
{numbers.map((number) => (
|
<ListItem key={'number-' + number.subtype} data-type={number.subtype} className={(number.subtype === 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={() => {
|
||||||
storeTextSettings.resetNumbers(number.type);
|
storeTextSettings.resetNumbers(number.subtype);
|
||||||
props.onNumber(number.type);
|
props.onNumber(number.subtype);
|
||||||
}}>
|
}}>
|
||||||
{number.thumb.length < 1 ?
|
<div id={`id-numbers-${number.subtype}`} className='item-number'></div>
|
||||||
<Icon className="thumb" style={{position: 'relative'}}>
|
|
||||||
<label>{t('Edit.textNone')}</label>
|
|
||||||
</Icon> :
|
|
||||||
<Icon className="thumb" icon={`icon-numbers-${number.type}`} />
|
|
||||||
}
|
|
||||||
</ListItem>
|
</ListItem>
|
||||||
))}
|
))}
|
||||||
</List>
|
</List>
|
||||||
))}
|
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
|
@ -141,6 +141,7 @@
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
flex-wrap: wrap;
|
flex-wrap: wrap;
|
||||||
|
width: auto;
|
||||||
padding-left: 18px;
|
padding-left: 18px;
|
||||||
padding-right: 18px;
|
padding-right: 18px;
|
||||||
padding-bottom: 14px;
|
padding-bottom: 14px;
|
||||||
|
|
|
@ -570,25 +570,18 @@ const PageNumbers = observer(props => {
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<View className='numbers dataview'>
|
<View className='numbers dataview'>
|
||||||
{numberArrays.map((numbers, index) => (
|
<List className="row" style={{listStyle: 'none'}}>
|
||||||
<List className="row" style={{listStyle: 'none'}} key={'numbers-' + index}>
|
{numberArrays.map( number => (
|
||||||
{numbers.map((number) => (
|
<ListItem key={'number-' + number.subtype} data-type={number.subtype} className={(number.subtype === 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={() => {
|
||||||
storeTextSettings.resetNumbers(number.type);
|
storeTextSettings.resetNumbers(number.subtype);
|
||||||
props.onNumber(number.type);
|
props.onNumber(number.subtype);
|
||||||
}}>
|
}}>
|
||||||
{number.thumb.length < 1 ?
|
<div id={number.id} className='item-number'></div>
|
||||||
<Icon className="thumb" style={{position: 'relative'}}>
|
|
||||||
<label>{_t.textNone}</label>
|
|
||||||
</Icon> :
|
|
||||||
<Icon className="thumb" icon={`icon-numbers-${number.type}`} />
|
|
||||||
}
|
|
||||||
</ListItem>
|
</ListItem>
|
||||||
))}
|
))}
|
||||||
</List>
|
</List>
|
||||||
))}
|
|
||||||
</View>
|
</View>
|
||||||
);
|
);
|
||||||
});
|
});
|
||||||
|
|
Loading…
Reference in a new issue