From 9b16457b1773e1eb8b84d55457ccde4c3eb3ac72 Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 21 Apr 2021 12:44:29 +0300 Subject: [PATCH 1/6] =?UTF-8?q?Fix=20Bug=20=E2=84=9648073?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- apps/presentationeditor/mobile/src/view/add/AddLink.jsx | 9 ++++++++- apps/spreadsheeteditor/mobile/src/view/add/AddLink.jsx | 8 +++++++- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/apps/presentationeditor/mobile/src/view/add/AddLink.jsx b/apps/presentationeditor/mobile/src/view/add/AddLink.jsx index 621df428c..b93c67d65 100644 --- a/apps/presentationeditor/mobile/src/view/add/AddLink.jsx +++ b/apps/presentationeditor/mobile/src/view/add/AddLink.jsx @@ -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) + }} /> : { 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' : ''} /> } From 62fe8656991b5c28e653e99071c8019acf3615b7 Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 21 Apr 2021 14:23:51 +0300 Subject: [PATCH 2/6] =?UTF-8?q?Fix=20Bug=20=E2=84=9647943?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../mobile/src/controller/edit/EditText.jsx | 4 ++-- apps/presentationeditor/mobile/src/view/edit/EditText.jsx | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/apps/presentationeditor/mobile/src/controller/edit/EditText.jsx b/apps/presentationeditor/mobile/src/controller/edit/EditText.jsx index 2b9ce3ae1..e7879a3d8 100644 --- a/apps/presentationeditor/mobile/src/controller/edit/EditText.jsx +++ b/apps/presentationeditor/mobile/src/controller/edit/EditText.jsx @@ -198,9 +198,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(); diff --git a/apps/presentationeditor/mobile/src/view/edit/EditText.jsx b/apps/presentationeditor/mobile/src/view/edit/EditText.jsx index 5d8b636f8..bddc3defa 100644 --- a/apps/presentationeditor/mobile/src/view/edit/EditText.jsx +++ b/apps/presentationeditor/mobile/src/view/edit/EditText.jsx @@ -327,13 +327,13 @@ const PageAdditionalFormatting = props => { - {!isAndroid &&
{letterSpacing + ' ' + Common.Utils.Metric.getCurrentMetricName()}
} + {!isAndroid &&
{Number(letterSpacing).toFixed(2) + ' ' + Common.Utils.Metric.getCurrentMetricName()}
}
- {isAndroid && } + {isAndroid && } From f8d0499d2202f19ac5065e29f89992438d03cdb7 Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 21 Apr 2021 14:37:14 +0300 Subject: [PATCH 3/6] Fix Bug 48285 --- apps/documenteditor/mobile/src/view/settings/Settings.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/apps/documenteditor/mobile/src/view/settings/Settings.jsx b/apps/documenteditor/mobile/src/view/settings/Settings.jsx index 920df80ca..fc3d53140 100644 --- a/apps/documenteditor/mobile/src/view/settings/Settings.jsx +++ b/apps/documenteditor/mobile/src/view/settings/Settings.jsx @@ -113,7 +113,7 @@ const SettingsList = inject("storeAppOptions")(observer(props => { {navbar} {!props.inPopover && - + } From c6b68ab7c668b95f79f79f5e091fa83f23075111 Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 21 Apr 2021 14:46:02 +0300 Subject: [PATCH 4/6] Fix Bug 47237 --- apps/common/mobile/lib/view/collaboration/Comments.jsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/apps/common/mobile/lib/view/collaboration/Comments.jsx b/apps/common/mobile/lib/view/collaboration/Comments.jsx index 2fd0dbdfa..11cfa7dfd 100644 --- a/apps/common/mobile/lib/view/collaboration/Comments.jsx +++ b/apps/common/mobile/lib/view/collaboration/Comments.jsx @@ -718,7 +718,9 @@ const CommentList = inject("storeComments", "storeAppOptions")(observer(({storeC
{comment.quote &&
{sliceQuote(comment.quote)}
} -
{comment.comment}
+
{ (comment.comment).includes('https://')? + window.open(comment.comment)}>{comment.comment} : +
{comment.comment}
}
{comment.replies.length > 0 &&
    {comment.replies.map((reply, indexReply) => { From a4d55fac575fb520f545d5aa86ff924db3df4f7a Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Wed, 21 Apr 2021 16:54:12 +0300 Subject: [PATCH 5/6] Fix Bug 49412 --- apps/documenteditor/mobile/src/view/edit/EditShape.jsx | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/apps/documenteditor/mobile/src/view/edit/EditShape.jsx b/apps/documenteditor/mobile/src/view/edit/EditShape.jsx index bbea37e37..f52bb9424 100644 --- a/apps/documenteditor/mobile/src/view/edit/EditShape.jsx +++ b/apps/documenteditor/mobile/src/view/edit/EditShape.jsx @@ -402,6 +402,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 ( @@ -427,7 +430,7 @@ const EditShape = props => { - @@ -438,7 +441,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)); From bacd0b5423fcf0072209b358b5b3ff0160edbeae Mon Sep 17 00:00:00 2001 From: ShimaginAndrey Date: Mon, 26 Apr 2021 09:20:52 +0300 Subject: [PATCH 6/6] Fix Bug 47237 modification --- apps/common/mobile/lib/view/collaboration/Comments.jsx | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/apps/common/mobile/lib/view/collaboration/Comments.jsx b/apps/common/mobile/lib/view/collaboration/Comments.jsx index 11cfa7dfd..e38997bcf 100644 --- a/apps/common/mobile/lib/view/collaboration/Comments.jsx +++ b/apps/common/mobile/lib/view/collaboration/Comments.jsx @@ -685,6 +685,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 ? window.open(link)} href={(link[0]==="w" ? "//" : "") + link} key={arrayComments.length}>{link} + : text)}) return ( @@ -718,9 +722,7 @@ const CommentList = inject("storeComments", "storeAppOptions")(observer(({storeC
{comment.quote &&
{sliceQuote(comment.quote)}
} -
{ (comment.comment).includes('https://')? - window.open(comment.comment)}>{comment.comment} : -
{comment.comment}
}
+
{arrayComments}
{comment.replies.length > 0 &&
    {comment.replies.map((reply, indexReply) => {