David Baker
f868cd6699
Fix border around persisted widgets
...
The PersistedElement had zero height so the border ended up in the
wrong place. Add a wrapper to fix the height back.
Fixes https://github.com/vector-im/riot-web/issues/7030
Fixes https://github.com/vector-im/riot-web/issues/7029
2018-07-18 11:52:57 +01:00
David Baker
e56feea9ec
Put always-on-screen widgets in top left
...
always-on-screen widgets now appear in the top-left where the
call preview normally is if you're not in the room that they're in.
Fixes https://github.com/vector-im/riot-web/issues/7007
Based off https://github.com/matrix-org/matrix-react-sdk/pull/2053
2018-07-12 18:43:49 +01:00
David Baker
8f10ee01c6
Implement always-on-screen capability for widgets
...
As per https://github.com/matrix-org/matrix-doc/issues/1354
This is whitelisted to only jitsi widgets for now as per comment,
mostly because any widget that we may make always-on-screen we need
to preemptively put in a PersistedElement container, which is
unnecessary for any other widget.
Apologies that this does a bunch of refactoring which could have
been split out separately: I only discovered what needed to be
refactored in the process of doing this.
Fixes https://github.com/vector-im/riot-web/issues/6984
2018-07-11 18:07:32 +01:00
David Baker
c780cd05a8
Change argument order of setRoomWidget
...
So when deleting a widget we can just omit the ones we don't need
2018-06-26 16:33:28 +01:00
David Baker
a88297d7a6
More code reuse
2018-06-26 16:27:17 +01:00
David Baker
6cf11a15e6
Move WidgetUtils to utils dir
2018-06-26 11:59:16 +01:00
David Baker
94125fb566
Fix widgets re-appearing after being deleted
...
Widgets would sometimes briefly re-appear after having been deleted.
This was because of the following race:
* User presses delete, send POST req, we set `deleting`. Widget hides.
* POST request completes, we unset `deleting` so widget unhides.
* State event comes down sync so widget hides again.
This fixes this by introducing `waitForRoomWidget` and using it to
wait until the state event comes down the sync until clearing the
`deleting` flag.
Since we now have `waitForRoomWidget`, this also uses it when adding
a widget so the 'widget saved' appears at the same time the widget
does.
2018-06-13 15:50:19 +01:00
Travis Ralston
254e8c358a
Remove unused imports
...
Signed-off-by: Travis Ralston <travpc@gmail.com>
2018-05-28 11:38:09 -06:00
Travis Ralston
98613748b6
Move Scalar Widget URL check to WidgetUtils
...
Signed-off-by: Travis Ralston <travpc@gmail.com>
2018-05-27 11:12:55 -06:00
Richard Lewis
b2c26e6984
Merge pull request #1920 from matrix-org/rxl881/refreshWidget
...
Add a "reload widget" button.
2018-05-24 18:11:22 +01:00
Richard Lewis
9753ee8d82
Better check of jitsi widget message origin.
2018-05-24 16:14:18 +01:00
Richard Lewis
a13d58f6c2
More thorough check of IM URL validity.
2018-05-24 14:58:59 +01:00
Richard Lewis
6df3371c6c
Add a "reload widget" button.
2018-05-22 19:14:54 +01:00
Luke Barnard
49a3770e92
Merge branch 'release-v0.12.4' into develop
2018-05-14 14:31:18 +01:00
Luke Barnard
cf8077e605
Set loading: false when iFrame finishes loading
2018-05-14 11:42:38 +01:00
Luke Barnard
6345e474f5
Remove unused conditional
2018-05-14 11:38:17 +01:00
Travis Ralston
9e11720191
Add setting to enable widget screenshots (if widgets declare support)
...
Fixes the remainder of https://github.com/vector-im/riot-web/issues/6708
Signed-off-by: Travis Ralston <travpc@gmail.com>
2018-05-12 14:30:59 -06:00
Luke Barnard
9c5c5e282b
Send visibility only when changed, and messaging is available
2018-05-11 18:20:23 +01:00
Luke Barnard
a419056040
Delinting
2018-05-11 18:20:14 +01:00
Luke Barnard
06919e22d6
When stickerpicker made visible, send visibility over postMessage
2018-05-11 18:20:00 +01:00
Luke Barnard
bd0301c666
Add API to send visibiliy actions to widgets
2018-05-11 18:17:55 +01:00
Luke Barnard
06898394eb
Send visibility only when changed, and messaging is available
2018-05-11 18:06:58 +01:00
Luke Barnard
1f2f3474ed
Delinting
2018-05-11 17:28:12 +01:00
Luke Barnard
8b049b2182
When stickerpicker made visible, send visibility over postMessage
2018-05-11 16:51:03 +01:00
Luke Barnard
4b6378a80d
Add API to send visibiliy actions to widgets
2018-05-11 16:22:54 +01:00
Luke Barnard
770e2d400e
Improve appearance of short-lived app loading spinner
...
by hiding it for 500ms - thereby only showing it if the loading is
taking a long time.
2018-05-09 17:28:41 +01:00
Luke Barnard
97b9316ec7
Fix issue incorrect positioning with widget loading indicator
...
by making sure to apply the correct CSS class to the parent
2018-05-09 17:28:18 +01:00
Luke Barnard
0c1846630c
Improve appearance of short-lived app loading spinner
...
by hiding it for 500ms - thereby only showing it if the loading is
taking a long time.
2018-05-09 16:54:01 +01:00
Luke Barnard
bcf003757c
Merge pull request #1884 from matrix-org/luke/fix-glitchy-widget-spinner
...
Fix issue incorrect positioning with widget loading indicator
2018-05-09 16:52:11 +01:00
Luke Barnard
59cbaf67bb
Fix issue incorrect positioning with widget loading indicator
...
by making sure to apply the correct CSS class to the parent
2018-05-09 15:48:53 +01:00
Richard Lewis
8e1ba6d139
Always allow users to edit their user widgets.
2018-05-08 22:44:49 +01:00
Richard Lewis
b2d6dd8f6e
Optionally hide widget popout button.
2018-04-25 16:28:27 +01:00
Richard Lewis
0f0e89d394
Add a button to 'pop out' widgets in to their own tab.
2018-04-25 12:49:30 +01:00
Richard Lewis
a41384a994
Fix function binding.
2018-04-04 23:45:47 +01:00
Richard Lewis
aefccb134c
Ensure deleting is set to false.
2018-03-29 16:56:25 +01:00
Richard Lewis
4ac9653ab9
Refactor widget postMessage API.
2018-03-28 12:22:06 +01:00
Richard Lewis
4d8f5072f7
Allow react performance profiling on widget iframes.
2018-03-16 10:20:14 +00:00
Richard Lewis
66ea78de65
Clean up whitelisted permission addition / logging.
2018-03-13 11:59:15 +00:00
Richard Lewis
8b311c706c
Null guard widget listener
2018-03-13 11:58:47 +00:00
Richard Lewis
f820374f9f
Logging.
2018-03-13 11:01:51 +00:00
Richard Lewis
de33294000
Center loading spinner.
2018-03-13 10:07:49 +00:00
Richard Lewis
b2d23b6999
Switch to 'm.sticker' message events. Allow whitelisting of wisget capabilities.
2018-03-12 13:56:02 +00:00
Richard Lewis
fdec4b36c9
Hide padding if last control.
2018-03-08 17:25:28 +00:00
Richard Lewis
3ab8b1f866
Hide sticker picker delete button and show minimise button.
2018-03-08 17:20:42 +00:00
Richard Lewis
2b0790b32b
Fix PropTypes.
2018-02-25 22:36:59 +00:00
Richard Lewis
b2bf4d4709
Merge branch 'develop' of https://github.com/matrix-org/matrix-react-sdk into rxl881/snapshot
2018-02-23 15:37:33 +00:00
Richard Lewis
d755b8284c
Remove logging and cleanup.
2018-02-23 15:22:56 +00:00
Richard Lewis
13bebd69c9
Made comment "react-style".
2018-02-21 23:35:57 +00:00
Richard Lewis
ecde099146
Fix typo.
2018-02-21 23:24:53 +00:00
Richard Lewis
7e8660cd37
Add comment for "is" attribute.
2018-02-21 23:23:44 +00:00