-
Notifications
You must be signed in to change notification settings - Fork 16
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Declare more detail of data
value of formatBackColor
and formatFontColor
#94
Comments
Safari on macOS sets the |
Thanks, then, Firefox will follow it. On the other hand, the unclear definition is a problem for me. Input Events should declare browses should use whether |
(I like |
data
value of formatBackColor
and formatFontColor
be null?data
value of formatBackColor
and formatFontColor
And if I think that when browser sets color, |
We should probably just follow what CSS OM does, which switches between |
Makes sense! |
There are two problems:
I suggest that in those cases, given value should be set to |
Do browsers even support invoking |
Firefox works as usual colors, e.g., if you select some text and call Edge works similarly. But using Blink does nothing except dispatching |
…zed color value when InputEvent.inputType is "formatBackColor" or "formatForeColor" r=smaug,m_kato,emilio Although neither Chrome nor Safari does not set InputEvent.data when the event is caused by `document.execCommand()` with `backColor`, `foreColor` nor `hiliteColor`, Safari supports styling color with touchbar and in that case, Safari sets it (*1). Additionally, currently Safari uses `rgb()` to represents a color value and using same rule to serializing color value for CSS OM matches Safari's behavior and can represent any valid color values. This patch makes given color value parsed and then serialized with same code in style system. If the value is `currentcolor`, `inherit`, `initial` or `reset`, sets the value as-is for now. Additionally, when given value is invalid, sets the value as-is for forward compatibility. Note that automated tests will be added into input-events-exec-command.html by the last patch. 1. w3c/input-events#94 (comment) Differential Revision: https://phabricator.services.mozilla.com/D19295 --HG-- extra : moz-landing-system : lando
…zed color value when InputEvent.inputType is "formatBackColor" or "formatForeColor" r=smaug,m_kato,emilio Although neither Chrome nor Safari does not set InputEvent.data when the event is caused by `document.execCommand()` with `backColor`, `foreColor` nor `hiliteColor`, Safari supports styling color with touchbar and in that case, Safari sets it (*1). Additionally, currently Safari uses `rgb()` to represents a color value and using same rule to serializing color value for CSS OM matches Safari's behavior and can represent any valid color values. This patch makes given color value parsed and then serialized with same code in style system. If the value is `currentcolor`, `inherit`, `initial` or `reset`, sets the value as-is for now. Additionally, when given value is invalid, sets the value as-is for forward compatibility. Note that automated tests will be added into input-events-exec-command.html by the last patch. 1. w3c/input-events#94 (comment) Differential Revision: https://phabricator.services.mozilla.com/D19295
FYI: I implemented |
I don't remember how I arrived at the wording "RGB function call", but searching the internet a bit, it basically covers @masayuki-nakano Are you saying that you will accept something other than "rgb()" and "rgba()"? As far as I know, the only place this shows up are special menus on Safari. Will Firefox also implement those menus? Will Firefox then have a menu where you can switch the color of a text to "inherit"?
|
No, Firefox does not have such interface. However, |
…zed color value when InputEvent.inputType is "formatBackColor" or "formatForeColor" r=smaug,m_kato,emilio Although neither Chrome nor Safari does not set InputEvent.data when the event is caused by `document.execCommand()` with `backColor`, `foreColor` nor `hiliteColor`, Safari supports styling color with touchbar and in that case, Safari sets it (*1). Additionally, currently Safari uses `rgb()` to represents a color value and using same rule to serializing color value for CSS OM matches Safari's behavior and can represent any valid color values. This patch makes given color value parsed and then serialized with same code in style system. If the value is `currentcolor`, `inherit`, `initial` or `reset`, sets the value as-is for now. Additionally, when given value is invalid, sets the value as-is for forward compatibility. Note that automated tests will be added into input-events-exec-command.html by the last patch. 1. w3c/input-events#94 (comment) Differential Revision: https://phabricator.services.mozilla.com/D19295 UltraBlame original commit: ef76c4985c1a632742814949279816207396ff38
…zed color value when InputEvent.inputType is "formatBackColor" or "formatForeColor" r=smaug,m_kato,emilio Although neither Chrome nor Safari does not set InputEvent.data when the event is caused by `document.execCommand()` with `backColor`, `foreColor` nor `hiliteColor`, Safari supports styling color with touchbar and in that case, Safari sets it (*1). Additionally, currently Safari uses `rgb()` to represents a color value and using same rule to serializing color value for CSS OM matches Safari's behavior and can represent any valid color values. This patch makes given color value parsed and then serialized with same code in style system. If the value is `currentcolor`, `inherit`, `initial` or `reset`, sets the value as-is for now. Additionally, when given value is invalid, sets the value as-is for forward compatibility. Note that automated tests will be added into input-events-exec-command.html by the last patch. 1. w3c/input-events#94 (comment) Differential Revision: https://phabricator.services.mozilla.com/D19295 UltraBlame original commit: ef76c4985c1a632742814949279816207396ff38
…zed color value when InputEvent.inputType is "formatBackColor" or "formatForeColor" r=smaug,m_kato,emilio Although neither Chrome nor Safari does not set InputEvent.data when the event is caused by `document.execCommand()` with `backColor`, `foreColor` nor `hiliteColor`, Safari supports styling color with touchbar and in that case, Safari sets it (*1). Additionally, currently Safari uses `rgb()` to represents a color value and using same rule to serializing color value for CSS OM matches Safari's behavior and can represent any valid color values. This patch makes given color value parsed and then serialized with same code in style system. If the value is `currentcolor`, `inherit`, `initial` or `reset`, sets the value as-is for now. Additionally, when given value is invalid, sets the value as-is for forward compatibility. Note that automated tests will be added into input-events-exec-command.html by the last patch. 1. w3c/input-events#94 (comment) Differential Revision: https://phabricator.services.mozilla.com/D19295 UltraBlame original commit: ef76c4985c1a632742814949279816207396ff38
Currently, no browser sets
data
attribute to "RGB function call" declared by Input Events even wheninputType
is eitherformatBackColor
orformatFontColor
.Additionally, these
inputType
are used only whenexecCommand
is used. Finally, the definition, "RGB function call" is too unclear, for example,rgb()
vs.rgba
, using int vs. percentage to each component, etc.So, I think that if we don't have any reasonable reasons to set
data
attribute for them,null
is better value.Otherwise, please declare the detail of "RGB function call" for compatibility between browsers.
The text was updated successfully, but these errors were encountered: