Bruno Windels
8820546f49
Merge pull request #3390 from matrix-org/bwindels/selection-color
...
Remove accent color as selection color
2019-09-06 09:12:42 +00:00
Bruno Windels
0252c7ae37
force pasting as plain text in new composer
2019-09-06 11:10:41 +02:00
Bruno Windels
556ccf45dc
Merge pull request #3389 from matrix-org/bwindels/cider-format-shortcuts
...
New composer: formatting keyboard shortcuts
2019-09-06 09:09:47 +00:00
Bruno Windels
2596281a7c
update last caret from update callback instead of input event
...
many editor updates are not caused by an input event, so
the last caret wasn't always up to date.
Updating the caret from the update callback ensures that every
time the editor contents is changed, the last caret is updated.
2019-09-06 11:09:01 +02:00
Bruno Windels
f4938f9d11
dont format empty ranges
2019-09-06 10:59:41 +02:00
Bruno Windels
06143ba7a1
show keyboard shortcuts in format button tooltip
2019-09-06 10:59:41 +02:00
Bruno Windels
bdcea6f21e
add shortcuts for formatting
2019-09-06 10:59:41 +02:00
Bruno Windels
de787c798c
Merge pull request #3387 from matrix-org/bwindels/cider-formatbar-tooltips
...
New composer: format bar tooltips
2019-09-06 08:52:00 +00:00
Bruno Windels
042822c90a
copyright is solely assigned to matrix foundation now, copy paste error
2019-09-06 10:39:19 +02:00
Bruno Windels
d6a493a2b1
fixup: language strings moved
2019-09-06 10:39:19 +02:00
Bruno Windels
b4b9c7d072
Add tooltip for format buttons
2019-09-06 10:39:19 +02:00
Bruno Windels
da29057fd8
move format bar to own component
2019-09-06 10:39:19 +02:00
Bruno Windels
02681d50b9
Merge pull request #3386 from matrix-org/bwindels/cider-formatbar
...
New composer: show format bar on selection
2019-09-06 08:38:01 +00:00
Bruno Windels
92c0c1a4e2
add comment about positioning the format bar
2019-09-06 10:29:18 +02:00
Bruno Windels
d2949babcd
copyright is solely assigned to matrix foundation now, copy paste error
2019-09-06 10:29:12 +02:00
Travis Ralston
af35cdc2ea
Support sending hidden read receipts
...
Fixes https://github.com/vector-im/riot-web/issues/2527
2019-09-05 20:30:19 -06:00
J. Ryan Stinnett
d5552e4a17
Add bound 3PID warning when changing IS as well
...
This extends the bound 3PID warning from the disconnect button to also appear
when changing the IS as well. At the moment, the text is a bit terse, but will
be improved separately.
Fixes https://github.com/vector-im/riot-web/issues/10749
2019-09-05 17:52:46 +01:00
Bruno Windels
124b7135cd
make sure the update callback gets a caret when calling reset
2019-09-05 17:54:08 +02:00
J. Ryan Stinnett
46ee52a406
Merge pull request #3388 from matrix-org/jryans/bound-3pids-warning
...
Add new agreed URLs to account data instead of overwriting
2019-09-05 15:02:15 +01:00
Bruno Windels
39bbf9af24
remove accent color as selection color
2019-09-05 15:40:33 +02:00
Travis Ralston
26eb617bec
Merge pull request #3384 from matrix-org/travis/fix-pl
...
Fix member power levels in room settings
2019-09-05 07:16:52 -06:00
J. Ryan Stinnett
0929a9cc72
Add new agreed URLs to account data instead of overwriting
...
This changes terms account data storage to always add, rather than setting only
the current set of displayed URLs.
Fixes https://github.com/vector-im/riot-web/issues/10755
2019-09-05 13:38:32 +01:00
Bruno Windels
4ef9fa53ac
better i18n
2019-09-05 11:10:13 +02:00
Bruno Windels
e3d70f3999
ensure selection is not lost upon clicking format bar in chrome
2019-09-05 11:01:44 +02:00
Travis Ralston
d6adf0fd6d
Add responsible error handling because we're responsible people
2019-09-04 11:24:31 -06:00
Bruno Windels
af535986d2
fix css lint
2019-09-04 16:40:34 +02:00
Bruno Windels
2ea556e0b4
support update callback setting selection instead of caret
2019-09-04 16:40:34 +02:00
Bruno Windels
037ac29c57
be more forgiving with offset that don't have atNodeEnd=true
...
if index is not found, it means the last position should be returned
if there is any.
We still return -1 for empty documents, as index should always point
to a valid part if positive.
2019-09-04 16:40:34 +02:00
Bruno Windels
42c37d8293
fixup: improve quote and code block newline handling
2019-09-04 16:40:34 +02:00
Bruno Windels
e0668e8517
improve algorithm to reduce selection to text node + charactar offset
...
this follows the documentation of {focus|anchor}{Offset|Node} better
and was causing problems for creating ranges from the document selection
when doing ctrl+A in firefox as the anchorNode/Offset was expressed
as childNodes from the editor root.
2019-09-04 16:40:34 +02:00
Bruno Windels
4691108a16
only increase offset if caret hasn't been found yet
...
also rename caret away as this isn't used for the caret solely anymore
2019-09-04 16:40:34 +02:00
Bruno Windels
7a01d1407f
make _replaceRange internal only
2019-09-04 16:40:34 +02:00
Bruno Windels
4c04bc19c9
fixup: remove now unused import
2019-09-04 16:40:34 +02:00
Bruno Windels
6e694c113a
add support for inline/block code formatting
2019-09-04 16:40:34 +02:00
Bruno Windels
b35a3531bb
move quote formatting out of react component
2019-09-04 16:40:34 +02:00
Bruno Windels
b72d1a78ec
move inline formatting code out of react component
2019-09-04 16:40:34 +02:00
Bruno Windels
47d8d86bbe
whitespace (in model)
2019-09-04 16:40:23 +02:00
Bruno Windels
7f501b2aef
first impl of quote formatting
2019-09-04 16:40:13 +02:00
Bruno Windels
d4c7992f5a
first impl of inline formatting
2019-09-04 16:39:56 +02:00
Bruno Windels
e7db660820
fixup: css, we have 5 buttons
2019-09-04 16:39:07 +02:00
Bruno Windels
c15dfc3c05
make Range start and end public
2019-09-04 16:38:42 +02:00
Bruno Windels
7dc39baaf3
implement bold support in format bar
2019-09-04 16:35:03 +02:00
Bruno Windels
77b14beb1f
add getter for intersecting parts of range, and total length
...
we'll need this when replacing selection, to preserve
newlines, etc ... in the selected range (e.g. we can't just
use range.text).
2019-09-04 16:35:03 +02:00
Bruno Windels
48f1bf1816
sort positions in Range constructor, so start always comes before end
2019-09-04 16:35:03 +02:00
Bruno Windels
65ddfc0a50
show format bar when text is selected
2019-09-04 16:35:03 +02:00
Bruno Windels
4575aaa9f6
Merge pull request #3382 from matrix-org/bwindels/escape-command-slash
...
New composer: allow escaping the first slash to not write a command
2019-09-03 16:04:23 +00:00
Bruno Windels
9a409a7acc
Merge pull request #3381 from matrix-org/bwindels/plain-command
...
/plain command to bypass markdown conversion
2019-09-03 16:04:07 +00:00
J. Ryan Stinnett
3cb06c01b7
Merge pull request #3385 from matrix-org/jryans/email-invite-text
...
Improve email invite preview messaging
2019-09-03 16:58:14 +01:00
J. Ryan Stinnett
261bdab156
Fix indent
2019-09-03 16:55:17 +01:00
J. Ryan Stinnett
67299842e3
Use more specific messaging for email invite preview
...
This changes email invite previews to check more specific cases about whether
the email has been added to your account, you have an IS, the email is bound,
etc.
In addition, it always allows you to join if you want to.
Fixes https://github.com/vector-im/riot-web/issues/10669
2019-09-03 15:41:53 +01:00