Commit graph

17865 commits

Author SHA1 Message Date
Szymon Kłos
c0b0897aa3 clipboard: notebookbar: show hint with keyboard shortcuts for Paste
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I73ba7d030810ccadbed828bce19e64f0cadbcfe7
2022-03-30 09:29:24 +02:00
Szymon Kłos
f2b1c72ac8 jsdialog: prevent us from unsafe-eval error
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I641237fd5f446a9482f9edec92a29fd948491a60
2022-03-30 09:29:24 +02:00
Szymon Kłos
33ffdcb1e7 clipboard: notebookbar: show Paste Special entry
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I485b70b8063fa6f2660d89ecd22bd72858b7a168
2022-03-30 09:29:24 +02:00
Szymon Kłos
fbe10e41bb clipboard: introduce paste special menu entries
also move paste special popup code to the clipboard.js
so it is easiet to share code

Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
Change-Id: I86bb1696ff78e3cef5425478cc3fb56cf47916b8
2022-03-30 09:29:24 +02:00
Pedro Pinto Silva
3c1185aca3 Improve edit button visibility when infobar, snackbar is present
Before we were showing edit button only if the snackbar was not present
in the DOM. The goal here was to avoid overlapping elements (bar + FAB).

However and since the infobar can be present in the DOM but set to
display none this would cause another problem: no edit button and no
infobar visible to the user.

Solution:
 - Make use of the existent css class .hidden (which sets it to display
 none) so we can then in the css side show the Edit FAB only after them
 snacbar is dismissed.

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I31be2dfeb1bcb08b971074466a24db719320f8f4
2022-03-29 14:31:21 +02:00
Pranam Lashkari
892fa8f835 fixed edit button not appearing in ipads
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: I949b3bc6d72541cba18867847cd43f0c6e57a32f
2022-03-29 14:31:21 +02:00
Mert Tumer
aa7eda472b fix trackchange comments are not displayed on docload
fix typo on clearList loop that prevents skipping trackchange
comments from being deleted

Also I removed the line in WriterTileLayer.js containing
clearList because clearList is already called on importComments
function so it was unnecessary

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ic4086a80b126aec62e382078f53d68bc17da8a1c
2022-03-29 13:46:43 +02:00
Rash419
6a1bade376 wsd: handle locked_hosts case where different aliases might have different settings
so now real locked_host settings will be applied if the document accessed with alias

Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: Ib76704a4bf2c3da5dc7b83bbad98fe40b5c03316
2022-03-29 12:18:31 +02:00
Rash419
31d8822758 wsd: cleanup: moved all parsing related static methods and containers to HostUtil.cpp
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I8555522c6216f893b90ba4c27747314830f7abd2
2022-03-29 12:18:31 +02:00
Pedro Pinto Silva
8d9317daa8 Fix button order on HyperlinkDialog
Follow the same order as anywhere else such as annotations, JSdialog or
even tunneled dialogs:
primary action aligned to the left

Also update cypress test: Do not target button position related classes
instead, rely solely on main classes

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Iac209aa343f22ddfdbd5662eba43d7adaa3f0892
2022-03-28 14:15:44 +02:00
Mert Tumer
e0511aa1bd sanitize-url: bump package version to 6.0.0
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I7c58e3a417e7a247b781800a2ec93417d3b7bc8f
2022-03-28 14:38:20 +03:00
Mert Tumer
dc1242ad9b annotation: fix redline compact-selected comments have wrong structure
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I78f80e6e24306629bacbda57106c1c6b41dee09e
2022-03-28 11:06:45 +02:00
Mert Tumer
958b33d82d annotation: fix trackchange comment gets hidden on collapse
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I34c4ff51f72b040ad1c6183519a13d3f45f56545
2022-03-28 11:06:45 +02:00
Ashod Nakashian
71e1e54eb5 wsd: hostname is needed for SSL SNI
Since the hostname argument is passed
to both the base class of SslStreamSocket
and SSL_set_tlsext_host_name, and since
the base class's getter, also called
hostname(), is hidden by the argument,
we cannot move it.

An empty hostname can result in 403 Forbidden
from the server due to missing Server Name
Indication (SNI).

Change-Id: I27990f64f17ec3c81a4dd543a078807629cd0c20
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-03-27 22:32:38 +02:00
Michael Meeks
45f29fd773 Allow debug.html to be passed a WOPISrc for easier debugging.
Change-Id: I3e618dbb9aa6363974e0759e955dfe73e8787824
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-03-26 23:27:00 +00:00
Szymon Kłos
0227768d7c Notify server about visible slide
Fixes problem with:
- showing wrong slide number in statusbar
- inserting comment at correct page
in pdfs where we see slides in continuous mode.

Sending slide id from online to server is much easier
than calculating based on visible area on the server
where we have to put that data into TabControl widget
which is used in different places.

It updates visible slide on scroll and also when selected
from the previews bar.

Signed-off-by: Szymon Kłos <eszkadev@gmail.com>
Change-Id: I7f8a9458e415e17391a4a249e19fd97f8541debd
2022-03-26 15:12:50 +01:00
Tor Lillqvist
ed8c10dfb1 nftw() does not set errno on failure
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I7e768416b5113d71330148227aeceb941013c578
2022-03-25 21:29:53 +01:00
Andras Timar
9752cd0b80 Bump version to 22.05.0.1
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: Ib17a8e9a26d73c4f20ce9447bb65c75b50348a58
2022-03-25 17:06:14 +01:00
Michael Meeks
9f5c5dcdf4 Show (E) for experimental mode in help->about if present.
Change-Id: I00d6cb861c3050d5b4f80b0cb41e70012d0fe610
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-03-24 17:25:40 +00:00
Pedro Pinto Silva
c89b062aea Fix closebuttonwrapper position on tablet
- Make sure the close button is always place at the last position so even
if integrator adds additional icons the close button should always
appear afterwards and make sure it does get shrunk
- Force closebuttonwrapper to be positioned at the end (far left side)
by grow #userListHeader (even if invisible)
- Avoid positioning closebutton image with background-position
  - Simplify by just fixing the parent and centering the image

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I851744c75c132957b8754ce7a105e57625f986bc
2022-03-24 10:32:12 +01:00
Pedro Pinto Silva
8eaa96840b Allow notebookbar-tabs-container to occupy full width
Remove the now necessary max-width from tablets
- We now have those parent elements being set as flex box
and thus we have now no need to limit the max width of this container
- Plus by limiting the max-width we were hiding more of the tabs while
not gaining anything useful in return

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I1ef477902fd95a4751009f8bf08350b6ce88aa97
2022-03-24 10:32:12 +01:00
Mert Tumer
ab0ed2d6f5 annotation: fix layouting problem on selected comments
modify and reply causes relayouting due to expansion of the
commentsections but it is based on whether they are selected or not
currently. If they are already selected we dont relayout them again
and it causes overlapping. To avoid that we can simply unselect
comments just before reply or modify.

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ifc2e546504b36b46f98a9b22ce791b4279239457
2022-03-24 10:08:34 +01:00
Dennis Francis
98f9e65948 revert: add edit option in link dialog...
commit eb387cc7b1

At least in current master it is possible to right click on the link and
select 'Edit hyperlink' context menu item and the edit dialog(JS)
appears. So it seems there is no need for this workaround edit button
inside the warning 'JS' dialog box anymore.

Additional reason is that when help button is clicked on any
dialog(tunnelled or not) it shows a warning 'link' dialog that it is
about to open a external url, but this dialog has an unneeded edit
button because of the original commit.

Signed-off-by: Dennis Francis <dennis.francis@collabora.com>
Change-Id: I2d8434746c698deefe69b38bf9947202f4f95862
2022-03-24 14:33:01 +05:30
Pedro Pinto Silva
fb83f8e3a5 Switch hover color to a lighter color
We need to use a lighter/ highlight color for hover so we then be able
to use darker backgrounds for disabled status and even pressed status
(active)

Also this automatically fixes the hover status for on/off switchers on
the toolbar (e.g.:sidebar trigger). Now they also react onmouseover

With this change

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I5efc41e3e7d13c10cf2d714acefee08f99e6af1a
2022-03-23 23:10:57 +03:00
Pedro Pinto Silva
2ec92b2308 Add missing hover state for primary buttons
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ic1fea0b40bbbcbb6b77bfe29b3df1786da53b7e9
2022-03-23 23:10:57 +03:00
Pedro Pinto Silva
aec88d3d01 Refactor commentSection buttons to avoid using multiple css classes
This commit does not change functionality

Add generic 'button-secondary' and 'button-primary' to buttons
- so we don't need to hunt each button from annotations
(cancel, save, reply)

additional plus: targeting any css class that has button-primary allow
to target in the future cases like vex-dialog-button-primary

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ie70867e3248ff70afdbe154593e4d02ec24c46df
2022-03-23 23:10:57 +03:00
Pedro Pinto Silva
6e9a11211e Autofilter buttons do not need special css targeting
With bda34c9096 those btns are already
generated with the proper generic classes that hold those styles so,
no need to keep individually targeting them

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I87912913d3f7340b5ed4b06b8c658791eda56d4e
2022-03-23 23:10:57 +03:00
Pedro Pinto Silva
ca316c0f3d Remove duplicated n inactive margin from annotation btns
- Better to keep everything related to buttons in the btn.css file
- Also all margins are already being set in the btn.css file anyhow

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ic1d9f7e2b895604367571a93f593ef359659c57c
2022-03-23 23:10:57 +03:00
Andras Timar
0392facc6b Bump packaga version to 21.11.3.3
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I315b7d74bfe09f0820068dc7ca36960d024c492b
2022-03-23 16:42:48 +01:00
Pedro Pinto Silva
142097b340 Fix missing icons by creating iconURL aliases
- add possibility to specify name alias for icons that are
  generated via jsbuilder (sidebar, notebookbar). The goal here is to
  avoid having multiple duplicated icons with different names:
  Example: 2 identical SVG files were being used just because of their
  name.

Context: When unifying icons between sidebar and toolbar PR #4426 ,
9576137df51725b677342c606dcad8749eaf0622 we end up with icons without
images on:
  - Calc: Notebookbar
  - Calc: Sidebar
This happens because even though we want to use the same icons the uno
commands are actually different from ones used in writer and elsewhere
(uno.AlignLeft <> uno.LeftPara)

Note: Since the sidebar uno.commands come from core we really need to
use icon url alias. If that was not the case we could have used here the
newest compatibilityAliases introduced in
7e6f3d5590

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I49647f8a32665d0363259151c09131d8c5063783
2022-03-23 17:01:43 +03:00
Pedro Pinto Silva
4be9e29a86 Update build status links
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ib2109fa3149d2f3dfbda1291975aa74a3e33e981
2022-03-23 14:29:51 +01:00
Pedro Pinto Silva
1c6206814b Fix comment reply count color
- Partly revert 7e705fcf09
  - RGB expects rgb values. Hex annotation does not work: renders it
 transparent
- Avoid low contrast between font and background (white with light bg)
  - Use instead primary color

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Iad24d6bf30d2e62505254c70b174e9b9971cbeb1
2022-03-23 13:57:35 +01:00
Ashod Nakashian
4d2351e37f wsd: reduce logging noise in socket reads
Change-Id: I4305baf828ccb1ae71d3b3b12fa90a7aeb5e0928
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-03-23 13:31:58 +01:00
Pedro Pinto Silva
5fb8c05f51 Add missing icons for mobile
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I06c24a406eb77ab22cb863ce1b2d071aa07c6582
2022-03-23 09:54:54 +01:00
Rash419
ea35dbe350 wsd: added regex support for alias tag
Signed-off-by: Rash419 <rashesh.padia@collabora.com>
Change-Id: I2534ea9afa7d3d3bf10f91eeac44f70381acc76a
2022-03-22 14:13:22 +01:00
Pranam Lashkari
defef6a171 util: removed duplicate string trimming function
Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ia150975467d1df8a9d05c8543bcb5d7369d29099
2022-03-22 09:07:03 -04:00
Tor Lillqvist
a635f9b8a6 There is no type called COOLWSD::Server
Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I7ccf4960a4161fdc5b012d72787e94b490cb4a6d
2022-03-22 11:38:51 +02:00
Tor Lillqvist
037a0929f0 Remove two forward declarations from COOLWSD.hpp
Only one of them is needed, and only in COOLWSD.cpp itself.

Signed-off-by: Tor Lillqvist <tml@collabora.com>
Change-Id: I03864afdc13e778a2b8ce8205e135d679dddf13d
2022-03-22 11:38:51 +02:00
Ashod Nakashian
1022a7e78e Revert "wsd: exclude deprecated openssl API"
Apparently this breaks the build on at least
CentOS. Reverting for now.

This reverts commit 23f02b8929.

Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
Change-Id: Ie8f00bbc53a63098b473d625846c0b6fd4e074bd
2022-03-22 08:41:59 +01:00
Andras Timar
a96c224281 Bump package version to 21.11.3.2
Signed-off-by: Andras Timar <andras.timar@collabora.com>
Change-Id: I5cf03151cf77b9f6031e42c61713f4b3acf4e9e8
2022-03-21 21:48:43 +01:00
Jan Holesovsky
4bef530844 Escape some parameters for a good measure
Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Change-Id: Ie5d2017ed6ce9f38623b42b336c5261be322b025
2022-03-21 21:35:27 +01:00
Gökay Şatır
2a944950e4 Typo in COOLWSD.cpp.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: Ib76fce22e70cb448712a33879c1484418bc75328
2022-03-21 21:34:25 +01:00
Michael Meeks
16386b9aaf Re-work welcome configuration.
Change-Id: Ia99eb5b587a849d32d7d4f392c15f84db2423e95
Signed-off-by: Michael Meeks <michael.meeks@collabora.com>
2022-03-21 21:34:25 +01:00
Gökay Şatır
32b85273d7 Add condition for infobar.
Signed-off-by: Gökay Şatır <gokaysatir@collabora.com>
Change-Id: I4df356663efa91207ef310341b7b08992bcb77de
2022-03-21 14:22:04 -04:00
Pedro Pinto Silva
2bb379afa6 Fix overflow property for FF
prefer universal value as opposed to WebKit-based and blink only
value

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ie0bff5de254829db6bffcd7a928629a98b1889ac
2022-03-21 15:32:52 +01:00
Mert Tumer
eec3ef97e2 android: fix unable to exit modified document
We dont upload to storage on mobile we save as locally
and copy the temp file into original on uno save result callback
Doing that once during close is enough since there is no
turning back and it cannot be possibly modified after

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I047626be862cdbcb86e083534555e45530f417a2
2022-03-21 16:44:50 +03:00
Pedro Pinto Silva
0e5e1efcd0 Allow items to be shown invisible on the TopToolbar
This is important because we in many places might want to still have the
respective element's space but without actually showing it.
Example: divider's space without that being represented by a bezel
- And add this new property to breaks surounding dropdown menus

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ib58cc9564144c4ad48fa240878a3654add5d4d03
2022-03-21 11:23:52 +01:00
Mert Tumer
585974e371 mobile: fix fullscreen presentation does not work on readonly mode
we send the slideshow buttons reference to onClick function
in that item.disabled is false but later we reassign it from
w2ui get function and then it becomes disabled true on readonlymode
The logic is incorrect because onClick function does not respect
wheter the item is passed or not and tries to reassign it anyway.

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I025e26c455a7673a002f894f49452b360550b178
2022-03-21 10:06:13 +01:00
Ashod Nakashian
23f02b8929 wsd: exclude deprecated openssl API
There are no deprecated API currently in use,
but that is a moving target as we upgrade openssl.
This prevents any accidental use of deprecated API
and will reveal any deprecated API used in any
particular build.

Change-Id: I969f7f7c4efe163d4704dea9aab45c09550baa40
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-03-21 08:57:41 +00:00
Ashod Nakashian
140b4f9c08 wsd: minor improvements to StringVector::equals overloads
Change-Id: Ifa975e579392151bef422ff985a93abf3129dfeb
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-03-21 08:57:41 +00:00