Merge branch 'feature/fix-bug-shimaginA' into develop
This commit is contained in:
commit
295bc949c9
|
@ -703,6 +703,10 @@ const CommentList = inject("storeComments", "storeAppOptions")(observer(({storeC
|
|||
}
|
||||
};
|
||||
|
||||
let arrayComments = []
|
||||
comment.comment && comment.comment.replace(/((?:https?:\/\/|ftps?:\/\/|\bwww\.)(?:(?![.,?!;:()]*(?:\s|$))[^\s]){2,})|(\n+|(?:(?!(?:https?:\/\/|ftp:\/\/|\bwww\.)(?:(?![.,?!;:()]*(?:\s|$))[^\s]){2,}).)+)/gim,
|
||||
(match, link, text) => {console.log(match); arrayComments.push(link ? <a onClick={() => window.open(link)} href={(link[0]==="w" ? "//" : "") + link} key={arrayComments.length}>{link}</a>
|
||||
: text)})
|
||||
return (
|
||||
<Fragment>
|
||||
<Toolbar position='bottom'>
|
||||
|
@ -736,7 +740,7 @@ const CommentList = inject("storeComments", "storeAppOptions")(observer(({storeC
|
|||
</div>
|
||||
<div slot='footer'>
|
||||
{comment.quote && <div className='comment-quote'>{sliceQuote(comment.quote)}</div>}
|
||||
<div className='comment-text'><pre>{comment.comment}</pre></div>
|
||||
<div className='comment-text'><pre>{arrayComments}</pre></div>
|
||||
{comment.replies.length > 0 &&
|
||||
<ul className='reply-list'>
|
||||
{comment.replies.map((reply, indexReply) => {
|
||||
|
|
|
@ -441,6 +441,9 @@ const EditShape = props => {
|
|||
const { t } = useTranslation();
|
||||
const _t = t('Edit', {returnObjects: true});
|
||||
const canFill = props.storeFocusObjects.shapeObject.get_ShapeProperties().get_CanFill();
|
||||
const storeShapeSettings = props.storeShapeSettings;
|
||||
const shapeObject = props.storeFocusObjects.shapeObject;
|
||||
const wrapType = storeShapeSettings.getWrapType(shapeObject);
|
||||
return (
|
||||
<Fragment>
|
||||
<List>
|
||||
|
@ -466,7 +469,7 @@ const EditShape = props => {
|
|||
<ListItem title={_t.textReplace} link='/edit-shape-replace/' routeProps={{
|
||||
onReplace: props.onReplace
|
||||
}}></ListItem>
|
||||
<ListItem title={_t.textReorder} link='/edit-shape-reorder/' routeProps={{
|
||||
<ListItem disabled={wrapType === 'inline' ? true : false } title={_t.textReorder} link='/edit-shape-reorder/' routeProps={{
|
||||
onReorder: props.onReorder
|
||||
}}></ListItem>
|
||||
</List>
|
||||
|
@ -477,7 +480,7 @@ const EditShape = props => {
|
|||
)
|
||||
};
|
||||
|
||||
const EditShapeContainer = inject("storeFocusObjects")(observer(EditShape));
|
||||
const EditShapeContainer = inject("storeFocusObjects","storeShapeSettings")(observer(EditShape));
|
||||
const PageShapeStyle = inject("storeFocusObjects", "storeShapeSettings")(observer(PageStyle));
|
||||
const PageShapeStyleNoFill = inject("storeFocusObjects", "storeShapeSettings")(observer(PageStyleNoFill));
|
||||
const PageShapeCustomFillColor = inject("storeFocusObjects", "storeShapeSettings", "storePalette")(observer(PageCustomFillColor));
|
||||
|
|
|
@ -118,7 +118,7 @@ const SettingsList = inject("storeAppOptions")(observer(props => {
|
|||
{navbar}
|
||||
<List>
|
||||
{!props.inPopover &&
|
||||
<ListItem title={!_isEdit ? _t.textFind : _t.textFindAndReplace} link='#' searchbarEnable='.searchbar' onClick={closeModal} className='no-indicator'>
|
||||
<ListItem disabled={appOptions.readerMode ? true : false} title={!_isEdit ? _t.textFind : _t.textFindAndReplace} link='#' searchbarEnable='.searchbar' onClick={closeModal} className='no-indicator'>
|
||||
<Icon slot="media" icon="icon-search"></Icon>
|
||||
</ListItem>
|
||||
}
|
||||
|
|
|
@ -202,9 +202,9 @@ class EditTextController extends Component {
|
|||
let spacing = curSpacing;
|
||||
|
||||
if (isDecrement) {
|
||||
spacing = (spacing === null || spacing === undefined) ? 0 : Math.max(-100, --spacing);
|
||||
spacing = (spacing === null || spacing === undefined || spacing === NaN) ? 0 : Math.max(-100, --spacing);
|
||||
} else {
|
||||
spacing = (spacing === null || spacing === undefined) ? 0 : Math.min(100, ++spacing);
|
||||
spacing = (spacing === null || spacing === undefined || spacing === NaN) ? 0 : Math.min(100, ++spacing);
|
||||
}
|
||||
|
||||
const properties = new Asc.asc_CParagraphProperty();
|
||||
|
|
|
@ -72,6 +72,7 @@ const PageLinkTo = props => {
|
|||
const PageLink = props => {
|
||||
const { t } = useTranslation();
|
||||
const _t = t('View.Add', {returnObjects: true});
|
||||
const regx = /["https://"]/g
|
||||
|
||||
const [typeLink, setTypeLink] = useState(1);
|
||||
const textType = typeLink === 1 ? _t.textExternalLink : _t.textSlideInThisPresentation;
|
||||
|
@ -114,7 +115,13 @@ const PageLink = props => {
|
|||
type="text"
|
||||
placeholder={_t.textLink}
|
||||
value={link}
|
||||
onChange={(event) => {setLink(event.target.value)}}
|
||||
onChange={(event) => {
|
||||
if (link.includes('https://')) {
|
||||
setDisplay(link)
|
||||
}
|
||||
setLink(event.target.value)
|
||||
setDisplay(event.target.value)
|
||||
}}
|
||||
/> :
|
||||
<ListItem link={'/add-link-to/'} title={_t.textLinkTo} after={displayTo} routeProps={{
|
||||
changeTo: changeTo,
|
||||
|
|
|
@ -328,13 +328,13 @@ const PageAdditionalFormatting = props => {
|
|||
</List>
|
||||
<List>
|
||||
<ListItem title={_t.textLetterSpacing}>
|
||||
{!isAndroid && <div slot='after-start'>{letterSpacing + ' ' + Common.Utils.Metric.getCurrentMetricName()}</div>}
|
||||
{!isAndroid && <div slot='after-start'>{Number(letterSpacing).toFixed(2) + ' ' + Common.Utils.Metric.getCurrentMetricName()}</div>}
|
||||
<div slot='after'>
|
||||
<Segmented>
|
||||
<Button outline className='decrement item-link' onClick={() => {props.changeLetterSpacing(letterSpacing, true)}}>
|
||||
{isAndroid ? <Icon icon="icon-expand-down"></Icon> : ' - '}
|
||||
</Button>
|
||||
{isAndroid && <label>{letterSpacing + ' ' + Common.Utils.Metric.getCurrentMetricName()}</label>}
|
||||
{isAndroid && <label>{Number(letterSpacing).toFixed(2) + ' ' + Common.Utils.Metric.getCurrentMetricName()}</label>}
|
||||
<Button outline className='increment item-link' onClick={() => {props.changeLetterSpacing(letterSpacing, false)}}>
|
||||
{isAndroid ? <Icon icon="icon-expand-up"></Icon> : ' + '}
|
||||
</Button>
|
||||
|
|
|
@ -87,7 +87,13 @@ const AddLinkView = props => {
|
|||
type="text"
|
||||
placeholder={_t.textLink}
|
||||
value={link}
|
||||
onChange={(event) => {setLink(event.target.value)}}
|
||||
onChange={(event) => {
|
||||
if (link.includes('https://')) {
|
||||
setDisplayText(link)
|
||||
}
|
||||
setLink(event.target.value)
|
||||
setDisplayText(event.target.value)
|
||||
}}
|
||||
className={isIos ? 'list-input-right' : ''}
|
||||
/>
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue