Commit graph

17429 commits

Author SHA1 Message Date
Ashod Nakashian
4b8d08bdd6 wsd: test: reduce UnitWOPISlow document size
Change-Id: Idf872404048918844704aa95f33fde299e64c409
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
2444e28059 wsd: reduce noisy logs
This reduces some logs from debug to trace,
especially in Socket where the amount of
activity is high, but the logs in question
don't add value in debug level.

Also supressed an error when superfluous.

This makes debug-level logs much more readable
and relevant to the main events.

Change-Id: Ie2698b56f320d15a09060cf2877477d9da0e1582
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
08461715cd wsd: test: stabilize UnitWOPILock
Transitioning the state must happen before
fiting the events that require the new state.

This was a source of random failures.

Also, improved other aspects and added
more assertions and logs.

Change-Id: I55d5a7d5f13eeedaff7f309402baaae37b0134d6
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
f4aa05cbf9 test: modernize http response in tests and simplify
And improve some test logs.

Change-Id: Ia65de99b5682abe55f677c6afca40289087f45e5
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
acbfc41afd wsd: remove unused resetUnloadRequested
Change-Id: Icb9ef1c02a9b8d31add5b305c3c1d09d3e251337
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
381d84ea8d wsd: getSteadyClockAsString now includes millis
Change-Id: I1c1e15c5271cd2d9346eaf3a29d11693020e419b
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
Ashod Nakashian
05dc8a0f84 test: improved state-machine helpers
Change-Id: I10c561ae4cf5e4471f1f9eafc9ffbb77badc7284
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-02-04 10:26:49 -05:00
andreas kainz
8c5461937c NB View Tab group commands according to LibO
First Group app specific commands
Second Group Zoom commands
Third Group visibility toggle

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I822d1ea8ef3460bea9869235b039749dad028c17
2022-02-04 09:33:46 +01:00
Pranam Lashkari
d4c7aaa4c4 fixed master slide previews not being updated
after switching to master view previews would remain unchanged
this patch will invalidate tiles for all the previews

Signed-off-by: Pranam Lashkari <lpranam@collabora.com>
Change-Id: Ie7320d625bd95fe80fc76a459b576d6148b39276
2022-02-04 01:16:13 +05:30
andreas kainz
5cdf727b75 Variable names for the color-palette
there are 4 type of color sections:
1. text
2. background
3. border
4. primary

and for each section there are
1. without extension for default color usage
2. -dark suffix for selected
3. -darker suffix for hover
4. -lighter for non available

with this setting the developer can choose
easy the section and the -suffix.

In addition there is primary color
which bring color the the apps and should depend
on the app so
- writer = LibO brand color blue,
- calc = LibO brand color green,
- ...

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I668b5505abd5d70345221bc79d921071c4a49cd7
2022-02-03 11:00:40 +01:00
andreas kainz
bf6178be91 Sidebar add padding to td and cell elements
In the past there was a padding which was removed
now padding was added again.

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I52f11aa3e36e331e47bee345212d103f2ebf1b65
2022-02-03 10:55:18 +01:00
Szymon Kłos
fd75b3b366 Do not request unnecessary image on selection
Avoid doubled PNG generation when graphic is selected.
We only need 'rendershapeselection' request to get preview.
'gettextselection' will only setup '_selectionContent' in
the Clipboard code but it will be never used as
`_getHtmlForClipboard` will ignore it for complex selection
with graphic.

Change-Id: Ic185aa3cb222ea97cf4c69fc65b5db350e568e42
Signed-off-by: Szymon Kłos <szymon.klos@collabora.com>
2022-02-03 10:36:35 +01:00
Mert Tumer
69ba14f358 sidebar: Don't show sidebar on pdf regardless of the permisson
To be safe, we can ignore the idea of this.map.isPermissionReadOnly()
control would always return true for PDF views and add
additional check for app.file.fileBasedView which is always
true and readonly true for PDF view

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I8f0a4401087c735508534404ee987bb35c3bb0fd
2022-02-03 11:24:41 +03:00
Pedro Pinto Silva
c66f4d5de6 Status bar: search: fix padding and height
- Remove extra left padding of input field parent
- Increase input field's height

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ic2b862cf2e6ad3bdc03504d5550b4deddd15d59b
2022-02-02 15:44:12 +01:00
Pedro Pinto Silva
c51feec5a2 Status bar: search: move inline styles to CSS file
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I3165ed4ce504845a0dd9e3876b03260766d63a75
2022-02-02 15:44:12 +01:00
Henry Castro
7b8ee90ceb browser: ensure no welcome dialog is shown if
the servers are down.

Change-Id: Ie06a833af3be1063690c1a854bcbaa0b30fe6e08
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-02-02 15:30:24 +01:00
Pedro Pinto Silva
7e47d5f578 Notebookbar: Calc, Impress, Draw: add view tab
and move everything related to view application to that tab

Without this change items related with document layout and
interface view were mixed together within the same "layout" tab. This
makes it harder to scan and find the desired action.
	- Split Document layout commands and interface commands by creating a
	new tab.

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I9d9d7fe88ceae8bc057946e20628132ee63577a0
2022-02-02 14:48:54 +01:00
Pedro Pinto Silva
1a1a68b962 Notebookbar: Remove start presentation from shortcutsBar
similar to what has been done with fullscreen command:
8db1fc9bc8

The current is noW present within the notebookbar tabs

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I30822df1a84d62f7c000a3a39df95e84640ffebc
2022-02-02 14:48:54 +01:00
Mert Tumer
4c2ee39fb2 fix typo on accessing map and uiManager
Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: Ieeed3599ffa51450a5bca4157144dc225df2f470
2022-02-02 14:48:31 +01:00
Pedro Pinto Silva
29874bd159 Notebookbar: Set ruler toggle to react to visibility
- Make sure a trigger is fired no matter the UI mode
	- Handle it (do anything) just from withing the NB widget
	(get proper css classes)

Note: similar to what we did with statusbar in:
e384c561798e7616f10e763788e92acec6caff9c

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I6c8a38f2e426f20cc5b7a06241f7a92fa4d938e4
2022-02-02 09:39:06 +01:00
Pedro Pinto Silva
fc810d1495 Notebookbar: Writer: move interface actions to view tab
Without this change items related with document layout and
interface view were mixed together within the same "layout" tab. This
makes it harder to scan and find the desired action.
	- Split Document layout commands and interface commands by creating a
	new tab.

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I625bb48a6c135d390f595511ddc8639ea5bdd2a8
2022-02-02 09:38:31 +01:00
Pedro Pinto Silva
8db1fc9bc8 Notebookbar: Remove full-screen from shortcutsBar
Fullscreen is not present within the notebookbar tabs and since it's a
not so frequent user interaction is better to remove it from the other
places

note: keeping the presentation mode present in the impress since it's
different command and it's not present in the NB at the moment

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I7f59387c32d71fddae0fb4001b0b098e71a1545b
2022-02-01 15:49:26 +01:00
Pedro Pinto Silva
1cfd136196 Notebookbar: Remove full-screen from hamburger menu
Fullscreen is not present within the notebookbar tabs and since it's a
not so frequent user interaction is better to remove it from the other
places

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I9f1d95ab30a8168471fe78a4590268f9338bcf81
2022-02-01 15:49:26 +01:00
Pedro Pinto Silva
4b25653860 Notebookbar: Set statusbar toggle's status on loading
Make sure the toggle also reacts not only to the user interaction¹ but
also at the startup time

1 Which is already done with:
- e384c561798e7616f10e763788e92acec6caff9c
 - from PR: https://github.com/CollaboraOnline/online/pull/4088/

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I29e401eede4fc11c821da91b66430ba99d1ec1aa
2022-02-01 13:36:55 +01:00
Pedro Pinto Silva
01cb40cffe Notebookbar: Set statusbar toggle to react to visibility
- Make sure a trigger is fired no matter the UI mode
	- Handle it (do anything) just from withing the NB widget
	(get proper css classes)

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ifdf18dc34a3b7d09e8224695ee0e72908b2166d8
2022-02-01 10:10:42 +01:00
Pedro Pinto Silva
50438f8238 Notebookbar: Calc: Add statusbar toggle to layout tab
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I4ee46b81ad6577f79075b0f4c8ab76e84bc6b786
2022-02-01 10:10:42 +01:00
Pedro Pinto Silva
33aadfbcb7 Notebookbar: Fix statusbar and ruler labels
They are toggles and not just on switchers

ref: 71831e2733

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: If3b1af0097723ba0caf66804dbb4e4e219f79abc
2022-02-01 10:10:42 +01:00
Andreas_K
1554b05a20 Classic Toolbar Menubar no juming up at hover menu element
If you hover at the classic toolbar at the menubar,
a border was shown and the string jump at 1px size.

Signed-off-by: Andreas_K <andreas_k@abwesend.de>
Change-Id: I5d03a380c2bfa34bd169bb12295d535875e54a5f
2022-01-31 13:32:36 +01:00
andreas kainz
535278f51f NB add SelectAll command to Layout tab
In the layout tab there are the object related stuff like
align and front/back. So I add there SelectAll command.

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I4cdd9fbb0351cede9cd78dd1edd50e0612d895f0
2022-01-28 17:04:34 +01:00
Andreas_K
ff2d2fea31 last-mod string removed underline and add hover accent color
if you hover over the last-mod string the color switch from
var(--color-text-lighter) to var(--color-text-accent).

In addition the text-decoration: underline was removed
cause it use text-lighter the focus shouldn't be there
with an underline.

Signed-off-by: Andreas_K <andreas_k@abwesend.de>
Change-Id: I750981730b6daa8605f8d70ebd3df4029f990e36
2022-01-28 11:41:37 +01:00
Alexandru Vlăduţu
65f8476818 browser: add optional function to process the URLs (internal and user
generated)

Signed-off-by: Alexandru Vlăduţu <alexandru.vladutu@1and1.ro>
Change-Id: If83611cc17d00dd049093de0a35caa7739f10400
2022-01-28 11:40:40 +01:00
andreas kainz
55f0155b03 Update Firstrecord and Lastrecord icon
2px thick lines same as other icons in the statusbar

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I08d493038047be16af4c8f4a12cdb22684decf11
2022-01-28 11:39:37 +01:00
Pedro Pinto Silva
6d3d2935d7 Rename: outdated loleflet strings
Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ibfb5de3dc5d4c5a57f4d50bf0a9bbc45df2ecadb
2022-01-27 16:15:51 +01:00
Miklos Vajna
4d6ca688f9 wsd, convert-to: allow specifying filter options as JSON
For example, to skip exporting the first page of a document:

curl -k -F "data=@3page.odg" -F "format=pdf" -F "options={\"PageRange\":{\"type\":\"string\",\"value\":\"2-\"}}" https://localhost:9980/cool/convert-to > out.pdf

https://gerrit.libreoffice.org/c/core/+/128849 has more examples.

Signed-off-by: Miklos Vajna <vmiklos@collabora.com>
Change-Id: I6c4ce25bc580dac041f2865f74c856780d6fe137
2022-01-27 13:33:24 +01:00
Ashod Nakashian
5cab06bd88 wsd: test: improve lock tests
Change-Id: Ia864e094daf5d794ffdac411d5ea22c98049afa4
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
2022-01-27 12:58:18 +03:00
Ashod Nakashian
8c7642b64a wsd: test: kill poco in pasteBlank
Signed-off-by: Ashod Nakashian <ashod.nakashian@collabora.co.uk>
(cherry picked from commit 49a74cc5e094d38abff172ed39752e3fdb2cfcc8)

Change-Id: Id5f544ca074590a7edffde57b1bdb865a7baba01
2022-01-27 12:58:18 +03:00
Mert Tumer
922ae4924a calc: Fix new comments do not check tabid on insert
it only checks the cellPos and this can cause
modifying the existing comment when we try to add
a new one if the same cell has a comment in another
tab already.

Signed-off-by: Mert Tumer <mert.tumer@collabora.com>
Change-Id: I69fd607b487fe18c9a48420b7df202b7d3db311d
2022-01-27 12:05:23 +03:00
Andreas Kainz
073a45c5fb Use monochrome color for Tab titles
AS opposed to color code the tabs' titles depending on the application
(doc type)

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I448428d37d2b9f607f176d05c9ef59ce79b1be28
2022-01-27 09:40:22 +01:00
Andreas Kainz
c60a563379 Use variables for text colors
there are 3 color var's added

var(--color-main-text)
this is the default text color EVERYWHERE

var(--color-text-accent)
will be used when a label was selected, or during hover
also for the filename accent text color was used

var(--color-text-lighter)
was use for saved date or when a label was disabled

PR was tested for classic and notebookbar
for the sidebar and dropdown elements.

Signed-off-by: andreas kainz <kainz.a@gmail.com>
Change-Id: I21795875e58b956081f2020422e77ccecd9bfba3
2022-01-27 09:40:22 +01:00
Pedro Pinto Silva
42aed6d4ef Rename BasicShapes string, again
It should be Shapes as it was before.

----

Context:
Regression started with following commit:
5c2e457eae

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I85f064e2158175dd7910b09d03c29255117c345e
2022-01-26 17:07:42 +01:00
Pedro Pinto Silva
a53fca9093 Infobar: mobile: hide edit btn when showing infobar
To avoid overlapping of elements (FAB + snackbar) with the same color

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I9254316a16b754fd6ea41a19f55dcacdf4b463e2
2022-01-26 16:46:06 +01:00
Pedro Pinto Silva
0b7376b3b4 Infobar: styling
- Pass additional class if in presence of an infobar
- Styling
- Also avoid hard coded pixels

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: Ic464e4b0928bf45cb395f4655fb2aeaa9d390118
2022-01-26 16:46:06 +01:00
Henry Castro
26d9015944 update check: fix wrong url replace
Change-Id: I911ac1425dca53242740e0584b34e3a25f00eeba
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00
Pedro Pinto Silva
8ef4bacea5 Feedack: Welcome: Apply different style to this dialog
in order to differentiate from the others since:
  - It's the welcome on-boarding
	- It's not possible to move the dialog

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I838a8ce0977864374372c46fa8e81945f57afaa2
2022-01-26 16:46:06 +01:00
Pedro Pinto Silva
344df86b76 Feedback: Welcome: Fix wrap position
- Avoid relaying on absolute measurements
  - So we don't need to keep track and maintain them
- Also make the wrapper occupy the whole screen
  - So the does not accidentally and unexpectedly starts to
  interact with the document itself underneath
  - Can be also good if we need/want to bind an action for when the
  user trigers a click outside of the dialog

Signed-off-by: Pedro Pinto Silva <pedro.silva@collabora.com>
Change-Id: I7c84554b933457800c9ddd579acfd76761baad23
2022-01-26 16:46:06 +01:00
Henry Castro
d056c872f5 wsd: fix missing port number
use Uri::getAuthority():
"Returns the authority part (userInfo, host and port) of the URI. "
.

Change-Id: I8c63a4c00cc1ad199f6f0cfd15f4e42fac4e7aaa
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00
Henry Castro
c4e7bd4605 browser: fallback for welcome dialog
Change-Id: Id05c658af02ab50ba45eaee8430b712bd4538a4c
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00
Henry Castro
bacb3f2df6 browser: catch exception from JSON.parse
Change-Id: I8d498e1b22593c66448ee2f0dead3ce3fc87ab99
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00
Henry Castro
5eff9950db browser: add basic close action to welcome.html
Change-Id: I7a2d4245f10aba23836b6b756d7473ccb531b4bf
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00
Henry Castro
924d63a764 browser: fix "isWelcomeOpen" check function
Change-Id: Iff6d4d82e07a9450bbd62b28c29504403d455c16
Signed-off-by: Henry Castro <hcastro@collabora.com>
2022-01-26 16:46:06 +01:00