Commit Graph

23057 Commits (67e3f819b5a0f52b1af9d0ea4392b32c3b4cb072)

Author SHA1 Message Date
Darshan-upadhyay1110 67e3f819b5 Backport: initializ UI after server reconnection
Signed-off-by: Darshan-upadhyay1110 <darshan.upadhyay@collabora.com>
Change-Id: I90cb6ad849708f4d5250f10df1fedb7e640da4a5
2024-05-02 06:29:33 +02:00
Rashesh Padia d712ddc747 fix: can't reconnect and get to edit mode after full server shutdown
- regresssion from eadaf3f606

Signed-off-by: Rashesh Padia <rashesh.padia@collabora.com>
Change-Id: If2b20c7960e3c242064fc04425b4f893612f6362
2024-05-01 23:49:07 +05:30
Aron Budea a6633c1401 Bump version to 23.05.11.1
Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I727f22a5d057b592b3f0d74bef2b33bd273e7699
2024-05-01 16:44:42 +02:00
Darshan-upadhyay1110 97e6bcac7f Hide outline format button for mobile
- Hide `Set outline format` uno button
- we will add this option again after fixing the dialog issue on mobile view for Outline option in `Bullets and numbering`
Signed-off-by: Darshan-upadhyay1110 <darshan.upadhyay@collabora.com>
Change-Id: I270b78b7b9f00fd7b0f12c348794e3d3da3e653e
(cherry picked from commit 4690d8ec28)
2024-04-30 18:36:41 +02:00
Pranam Lashkari f8c2617079 annotation: avoid resizing editing comment
problem:
when you try to reply to long comment, it would be resized
and subsequntly reply box will take space and other comments
will not make enough space for it

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I4d81904721e5bb196947598d0dca211ee9d480a6
2024-04-30 00:21:44 +01:00
Pranam Lashkari 21984b7dd2 annotation: fixed comments could not expand
problem:
when comment was on the edge of the document/screen(vertically)
resize was called which ultimately collapsed the comments in small screen
which could not be expanded unless scrolled further from edge.
It was more problematic for the threads,
if entire thread could not fit in the screen it was always failing to expand

regression from bac4161

it nullifies the effect from 81b00e7
now if comment is added at the end of the document and it goes beyond doc boundry
doc will not scroll automatically to make entire comment visible

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I198b4887ae19ca0c17ba1453960cd36a66beb04d
2024-04-30 00:21:44 +01:00
Pranam Lashkari e47b0663d4 annotation: fixed thread scrolling to root comment on action
problem:
when long thread did not fit on screen and actions were performed
on last comments of thread which put root comment out of view,
it will cause scroll back to root comment (i.e: reply)

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I23d699425dc2dff1cfeddf6ab9be7131f80c3a31
2024-04-30 00:21:44 +01:00
Pranam Lashkari 0374e71b67 annotation: avoid explicit unselect before select
select function now can take care of reselection and layout update

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I2a061643ec190d5b2d005b940923a28131ed6cb0
2024-04-30 00:21:44 +01:00
Pranam Lashkari bcc708ed9a annotation: make comment section scrollable with mouse
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ib6a2fee7ace81ffbc82ec4545e6f613f79c6734f
2024-04-30 00:21:44 +01:00
Attila Szűcs 93ddb923fc writer: fix annotation size regression
Hidden contentNodes (in annotation) may become visible during resize.
Looks like setting style.max-height also change style.display.

Now i set it only if style.display is not none.

Signed-off-by: Attila Szűcs <attila.szucs@collabora.com>
Change-Id: I30f2eb75cb3ccb5b43044cef856314b0e35b9300
2024-04-30 00:21:44 +01:00
Pranam Lashkari 61969fb224 macro: open document without macros enabled
problem:
when user selected disable macro in the opening dialog
document used to close and return to integrator
but now cancel button in csv import dialog is hidden,
so no need to distinguish there and we can continue to load without macros
In addition we still close the file if user clicks "X" button on title bar

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ie0c7d77954e099cb3c8a72c400c688b3ae1343c7
2024-04-29 23:33:36 +02:00
Szymon Kłos e020ea7370 css: fix button-box alignment
in 24.04 more elements are grid now, it seems to be a
regression in button box:
1. enable macro execution in coolwsd.xml
2. open spreadsheet with macro
Result: you see the dialog with buttons in 2 rows
Expected: all buttons are in the same row

it seems to be missing grid placement for left and right sections

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: Ic1a3479114e4f832e852b9bdf3d39d2669ae69bb
2024-04-29 22:52:34 +02:00
NickWingate b4f6317446 Sanitize presentation window title and url
Note the url sanitised is the url passed to
the iframe, not the url in the popup window

Signed-off-by: NickWingate <nick.wingate@collabora.com>
Change-Id: Idad9bfaa390d83cfb083b99144cb9d0a54705287
(cherry picked from commit ec0d89754d)
2024-04-29 19:00:49 +02:00
NickWingate ec25a236e1 Force slideshow popup to have blank url in firefox
Firefox has automatic url navigation when we use
document.write and changes the url to the parent
window. document.write may also cause additional
problems (see https://developer.mozilla.org/en-US/docs/Web/API/Document/write)
Instead change only the innerHTML of the document.

Signed-off-by: NickWingate <nick.wingate@collabora.com>
Change-Id: I55b88fd557af05b2a0e49adb7f08e9467dd4a4ba
(cherry picked from commit 4cfd274deb)
2024-04-29 19:00:49 +02:00
NickWingate 0b23d07b28 Add localization to popup title
Signed-off-by: NickWingate <nick.wingate@collabora.com>
Change-Id: I306120db1bcda043c92adad122e368e05c80f613
(cherry picked from commit 10f8e90d76)
2024-04-29 19:00:49 +02:00
NickWingate 824cf109e0 Change convoluted url and name in windowed presentation
Open an empty popup with a blank url, then set the
content of the popup to be our slideURL wrapped inside an
iframe with a user friendly title.
Focus the iframe on load so that arrowkey navigation works
and forward the eventlisterner of the iframe to the parent
window to watch for escape key calls

Signed-off-by: NickWingate <nick.wingate@collabora.com>
Change-Id: Ie1063095db51119fd45453b8b4b180fcacb6d7c1
(cherry picked from commit 50267a3aaa)
2024-04-29 19:00:49 +02:00
Szymon Kłos 1e0a06d66d Fix error on hide tooltip
Tooltip can be modified only when was already initialized.
Sometimes we tried to hide it without initilization.

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I6f4a18acef6be2d3c00548f8b4408c7876d6bdfa
(cherry picked from commit 6f44bbc600)
2024-04-29 18:43:51 +02:00
Pedro Pinto Silva a7f0e2e499 Fix unobutton's lack of pointer cursor
Before this commit buttons such as bold (in the notebookbar) or
sidebar button (in the top toolbar) would not change the cursor on hover

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ief075b4f4d187f6a5d87458d02077c0deaf69fe6
2024-04-29 15:21:27 +01:00
Pranam Lashkari ef3d1cc454 annotation: scroll to comment after resize comment list section
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Icbabf5dcdb6f1e01ca0271b2898df28f11810f35
2024-04-29 13:50:07 +01:00
Pranam Lashkari 0c1b7061b3 annotation: resize comment list section on view size change
problem:
in writer when comment is added at the end of document,
it may go out of view and covered by the status bar and can't scroll any further

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ia40ea128cd36a904ee5030bb7399da183e21f44d
2024-04-29 13:50:07 +01:00
Aron Budea dac726931b browser: Add correct class to Share / See History buttons in Impress
...as in other tabbed bar JS files.

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I29c43d9dc0ce4fa929e049e70171e0b8ab029088
(cherry picked from commit d471d93c1e)
2024-04-29 12:12:16 +01:00
Aron Budea 5e28e9bee2 Don't log warnings about version mismatch for admin console
It's only relevant for regular URLs that contain version hash.

Signed-off-by: Aron Budea <aron.budea@collabora.com>
Change-Id: I73afaa0559c3dddc09a8ed5f786fb5126e1c8f0c
(cherry picked from commit b38e1f41ea)
2024-04-29 06:23:19 -04:00
Méven Car 7b4d7d180b WopiStorage: turn err to warning logging for PutFile
Let the error detail the error origins.

Signed-off-by: Méven Car <meven.car@collabora.com>
Change-Id: I67a98dfe1001fd663af464ec5ec417330d0fbfb1
2024-04-29 06:22:13 -04:00
Rashesh Padia da0c010dba fix: zotero options not visible when viewId is zero
- regression from 179bfb65ab

Signed-off-by: Rashesh Padia <rashesh.padia@collabora.com>
Change-Id: I4554a5fcc9b0c5dce48c8b35ea32142ff1c323f3
2024-04-29 10:28:10 +02:00
Gülşah Köse d939220e01 Prevent opening multiple tooltip on drawing area widgets
We see multiple tooltip problem on drawing area widgets.
Example case:
    Add basic shape into a writer document
    Right click on shape and open Position and Size dialog
    Select the Rotation tab
    Hold the rotation angle widget and drag around itself
When you inspect the "Rotation Angle" tooltip, count may be 600
We expect only 1.

So we prevent to show another tooltip if we have already one.

Signed-off-by: Gülşah Köse <gulsah.kose@collabora.com>
Change-Id: I2f548f8c7afce8095e83a6faa3722e164f990210
2024-04-26 15:24:26 +02:00
Skyler f50b77cdd1 iOS: stop keyboard pushing content offscreen
Previously using the onscreen keyboard would shrink the visual viewport
while leaving the elements at the same size, meaning some of the content
had to be offscreen. As we scrolled the page to have the cursor in view,
this would move the notebook bar offscreen.

To avoid the possibility of the cursor leaving the screen or the bottom
toolbar being offscren, we can use the VisualViewport API to force the
logical viewport to have the same size as the visual one

This won't have an effect in iframes as the logical and visual viewport
in iframes are always the same, and we already scale to 100% height by
default anyway

Signed-off-by: Skyler <skyler.grey@collabora.com>
Change-Id: I07726bee8b61334f6a32e873ab2d5428fa60dca3
2024-04-24 21:53:42 +02:00
Pranam Lashkari 34b9fddd67 annotation: enable comment insertion from context menu
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: If5b949c36851664d5720042d3ff5c8394b2d3961
2024-04-24 19:30:25 +01:00
Skyler Grey 7ca85c29df Fix broken frozen columns mid-pinch-zoom
Previously the following issues were present when columns were frozen
- The frozen column was allowed to move, this was exacurbated when I
  made it easier to move in my 'calc: pinch-zoom:' commits,
  (3ba8257c64 to
  b378a0fd77). This is now fixed
- A regression was also introduced in that range where the selected cell
  marker would become offset if you placed it in a frozen section then
  pinched to zoom. This is also fixed

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: I07f70a32e5cb68aeb759fd6cad626b2d4c0eed72
2024-04-24 09:19:54 +02:00
Skyler Grey 17cc8f724e calc: pinch-zoom: fix hard edge when zoom-panning
Previously we clamped the pinch so it could not go outside the bounds of
the initial zoom pane (presumably this was intended to avoid you going
outside the map with your pinch).

Unfortunately, this is the initial bounds, causing a nasty edge when you
panned around too much, which is particularly noticable with the
improved zoom-pan ergonomics.

I decided to remove this altogether rather than scaling it correctly, as
I don't believe that a check to make sure you're not going outside the
map feels particularly natural when pinch-zooming around the document,
particularly as only the center of your pinch is checked.

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ib98ca91e82bbe7f2bb9986595fc5f7928e2206c9
2024-04-24 09:19:54 +02:00
Skyler Grey 2314d5b565 calc: pinch-zoom: Fix zoom end position
Previously the new zoom did not correctly calculate where the end of the
zoom should be centered, causing the zoom to jump when it finished.

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ic6c1eb032c66af764da4efca3f015af895e75600
2024-04-24 09:19:54 +02:00
Skyler Grey e9a1fbdbbe calc: pinch-zoom: stop cursor offset
Previously, overlayed elements such as the cursor did not properly
follow the new zoom as they were separately calculated. To fix this, we
can use the _getZoomDocPos function to calculate where these should be
drawn

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: I39d6c926895e72be03ad33e6a9221a4f740e9b50
2024-04-24 09:19:54 +02:00
Skyler Grey ff58ed6c72 calc: pinch-zoom: Recognize zoom start position
Previously, the document would not always properly follow your finger
when you tried to pan while in a pinch-zoom. In particular, we would
sometimes get this disatrously wrong (e.g. at some zoom levels we would
move our fingers one way and have the document go the other!).

I have rewritten the _getZoomDocPos function to avoid this, in
particular by adding a parameter to keep track of where our zoom started
from which lets us know where we need to zoom around. In the
mouse/button zoom case this doesn't change, but in the touchscreen zoom
case it informs us how much the viewport should have been moved.

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ia87d941651da43eb5c16c8ce10a2493e7214252a
2024-04-24 09:19:54 +02:00
Skyler Grey 783ea5eb44 Stop a leftover swipe action preventing a zoom
Previously if we were in animation from the end of a swipe and we started
a zoom, we would cut the animation but not continue to start a zoom. This
made surprising behavior when you could put down two fingers to stop the
ongoing movement but could not then zoom with them.

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ib4c6e686caaf78b3637563da6fcc914c06f3055a
2024-04-24 09:19:54 +02:00
Skyler Grey 15319eefb5 Use existing viewId in commentListSection avatar
In 79028c6f88 I replaced an instance of
using this.map._docLayer._viewId as if the user is not in the document
this becomes your own view ID and shows the wrong avatar. Unfortunately
I missed CommentListSection which has the same code.

As we already have a viewId fetched a little later down, I opted to use
it rather than get another myself

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Ieda06e03902effe9be8fef3623b73d3caeef6f65
2024-04-23 16:28:41 +01:00
Skyler Grey 17b803a39d comments: fix avatar when author is not in document
In e855aa6114 a regression was introduced
where a comment avatar was set to your avatar if the user was not in the
document

This commit returns it to the previous behavior, which had a "default"
avatar instead. It might instead be nice to embed avatars in the
document to avoid the avatars being missing, however the previous
behavior is far less confusing than the regressed behavior and is far
easier to get to than embedding avatars in the document

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: I82834089062b1e7c2570d9fd78c7e1a3077f4c96
2024-04-23 16:28:41 +01:00
Darshan-upadhyay1110 5198e24237 Fix header avatar have the same image of current UserList
Problem :
 - Open the document which have some comment from other User
 - we can see that they are same as the logged in user avatar

regression
    - this is a regression from commit e855aa6114
    - we were paasing url of user which is logged in and that should not happning for other user avatar image

Solution: - while setUserImage function pass viewId
    - this will help to identify the user Info from map
Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: I5ee8b41c2e58a4ba15ecf551b264f944aa926da8
2024-04-23 16:28:41 +01:00
Darshan-upadhyay1110 1186435452 User avatar should be consistent after mode change
- User avatar should first consider is there is already extract info available or not
- if we already have that image source data then please do not set default value
- also when mode change we do preform some refresh function on all icons
    - `map.on('themechanged', setupIcon, this);`
- in that case as well, first check if we have user extract info or not
- and based on that set image source URL

Change-Id: Ifbd543322f5222fa7717b40a5ae565ed2f3c9891
Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
2024-04-23 16:28:41 +01:00
Skyler Grey fde1aae796 mobile: Use SavedUIState=true
SavedUIState is a ui_defaults option to ignore any user preferences for
state when loading, it was added in
https://github.com/CollaboraOnline/online/pull/7575

We need to set SavedUIState explicitly on mobile, which the following
pulls do for iOS and Android respectively:
- https://github.com/CollaboraOnline/online/pull/7908
- https://github.com/CollaboraOnline/online/pull/7912

Unfortunately, setting it to false can cause some nasty bugs, such as
inability to change theme to light. It also intentionally ignores user
preferences when you reopen a document, but this isn't particularly
desirable on mobile.

I believe it to be an oversight that the option was set to `false`
rather than `true`, as `true` was the behavior before the ui_default
option was added and neither change gives a reason for it to be false
rather than true.

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: I30ce445db1b7e69a3b44eec3fb4689c463233b1f
2024-04-23 15:31:10 +01:00
Pranam Lashkari 3a70eac037 uno: .uno:SetDocumentProperties: add file path parameter
problem:
in LOK/online to support async save, files in jails may have
different extensions (ie: .upload, .uploading)
this caused problem to detect files as original file name may not exist.
As result property like file size were always set to 0

chronology of events:
1. File is saved normally with existing name
2. After saved we make it ready for upload and add extension .upload in "renameForUpload"(kit/ChildSession.cpp)
3  We change to .uploading extension when we are uploading (DocumentBroker::handleSaveResponse, DocumentBroker::uploadAfterLoadingTemplate)

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ibda40b0c134ef6baef9edb0427b3c56340924858
2024-04-22 19:45:48 +01:00
Caolán McNamara 03753b9dfb Revert "add parameter "theme" to load a document"
This reverts commit 100def4c80.

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I054ae3efc51bab3ba8e30011a6f4222f3b65e6ad
2024-04-22 09:39:37 +02:00
Caolán McNamara 5ec17a1e52 Revert "kit: fix missing theme option"
This reverts commit f549223eff.

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I59cdfb7eafabd5bc9aa9eda447734c55a4dc24b2
2024-04-22 09:39:37 +02:00
Caolán McNamara f15a52aa49 Revert "backport 23.05 equivalent of honoring window.uiDefaults.darkTheme"
This reverts commit 13dbd68bce.

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: If6f0bbaa4a27b3f174078f45ea62d0d8ec93a4a7
2024-04-22 09:39:37 +02:00
Caolán McNamara c6fbf7e91b if a sheet is removed or moved, re-request comment positions
a problem since:

commit 72b2ce4bb6
Author: Caolán McNamara <caolan.mcnamara@collabora.com>
Date:   Wed Oct 25 19:19:08 2023 +0100
    we don't need to round-trip through core to reposition notes

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: If00ae17a8e80ca3f8d2a530efa6cdba90207be56
2024-04-19 16:49:47 +01:00
Caolán McNamara c63deba8aa move these common calc annotation test blocks to calcHelper
Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: Ia67e29e447b333f4dfdfe25ec717cbdfc6dce043
2024-04-19 16:49:47 +01:00
Pranam Lashkari ac849f59cd added check for undefined properties
problem:
zotero was not loading because element.text didn't exist
on adding bibliography there was error to parse JSON,
because there's some more data in string after JSON

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: If34791ae7ca79ca7fd304b506cd483e929f4d2ac
2024-04-19 17:09:18 +02:00
Caolán McNamara 13dbd68bce backport 23.05 equivalent of honoring window.uiDefaults.darkTheme
if it exists as the default dark/light theme to use if there is
no explicit user setting for it

Related to: https://github.com/CollaboraOnline/online/issues/8734

similar issue as in 24.04 arises from similar 23.05 change of:

commit 100def4c80
Date:   Tue Feb 20 16:23:37 2024 -0400

    add parameter "theme" to load a document

Signed-off-by: Caolán McNamara <caolan.mcnamara@collabora.com>
Change-Id: I49596768ece16ceee1a74740877550122722d51a
2024-04-19 08:33:17 +02:00
Skyler Grey 7117f0216a ScrollSection: fix panning with RTL
Previously we did not take into account whether something was RTL when
scrolling it with ScrollSection. By introduing a new isRTL function to
check this, we can do something different (in this case scrolling the
other direction) if we are controlling an element that should be RTL.

We need to introduce a function, as whether we are using RTL can change
over the lifetime of the ScrollSection

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: If4261a3e32375f6127241b846b97a3b4ac29eb0b
2024-04-18 15:26:17 +00:00
Skyler Grey 268c9894a4 Draggable, TouchGesture: Fix panning with RTL
Previously when we were in RTL mode panning would be flipped. This
commit unflips it

Signed-off-by: Skyler Grey <skyler.grey@collabora.com>
Change-Id: Iea4d16918b054d355e6d8695e0dc1d6ededd6793
2024-04-18 15:26:17 +00:00
codewithvk 66c0b05e54 Added additional menu entries and a new sub-entry under Conditional formatting
- Added 'Contains text...' and 'Duplicate...' as menu entries under Conditional > Condition...
- Introduced a new sub-entry Top/Bottom Rules' under Conditional, with the following options:
    - Top n elements
    - Top n% (n percent)
    - Bottom n elements
    - Bottom n% (n percent)
    - Above Average
    - Below Average

These changes enhance the functionality of the Conditional formatting menu by incorporating commonly used options for users.

Signed-off-by: codewithvk <vivek.javiya@collabora.com>
Change-Id: I1c3c06b21a9d26e6a8966782c0af07381403c08f
Signed-off-by: codewithvk <vivek.javiya@collabora.com>
2024-04-18 02:14:25 +02:00
Rashesh Padia 179bfb65ab fix: duplicate `You` on reconnect
- it might happen viewinfo message arrives before status message,
viewinfo message update view list with old _viewId because new _viewId
after reconnection is not avaialable yet
- this patch fixes this by reseting the _viewId on socket close and call
updateviewlist event after client gets new _viewId from status message

Signed-off-by: Rashesh Padia <rashesh.padia@collabora.com>
Change-Id: I88a6ade574faa1368b1635db891fe87f89fa080e
2024-04-17 18:39:41 +01:00