Skip to content

Remove/deprecate maction element #26

Closed

Description

@fred-wang

Just opening this for the record...

I know that @kohlhase likes this element but I wonder if it is very useful in a modern web context where you can create your own JS effect. Maybe this should just be removed from MathML core and polyfill provided.

Activity

  1. added
    MathML Core
    MathML 4
    on Feb 22, 2019
  2. fred-wang commented on Feb 22, 2019

    @fred-wang
    Author

    For maction actiontype="input", this is related to @dani31415 's proposal in #12

    Other actiontypes like toggle, tooltip or status line could be implemented with JS like what MathJax do, so I'm sure people could write polyfill.

    Also note that maction actiontype="statusline" is a small security issue, since it known to be used to deceive people (e.g. to hide a "bad" URL).

  3. davidcarlisle commented on Feb 22, 2019

    @davidcarlisle
    Collaborator

    I don't think it should be deprecated in full mathml, we still need to support MathML in environments without JavaScript (Word Processors being a notable example with current MathML support) but I wouldn't have a problem with dropping it from core, presumably by the time you have specified its interaction with CSS and Javascript you have pretty much specified the required polyfill to go from a full mathml expression with maction, to a mathml core plus javascript polyfill equivalent.

  4. physikerwelt commented on Feb 22, 2019

    @physikerwelt
    Member

    we still need to support MathML in environments without JavaScript (Word Processors being a notable example with current MathML support)

    That is interesting. I would like to learn more about this aspect of MathML. Which WP are you thinking of? Are you aware of any WPs that are actively maintained that use this feature?

  5. physikerwelt commented on Feb 25, 2019

    @physikerwelt
    Member

    See also #12

  6. kohlhase commented on Mar 7, 2019

    @kohlhase

    Let me add my view (I agree that the current situation is problematic, and am open to any reasonable resolution)

    I know that @kohlhase likes this element but I wonder if it is very useful in a modern web context where you can create your own JS effect.

    Well I do (see below) and I don't (lots and lots of reasons, including that it is quite under-specified and looks like a solution from the early 2000s).
    I mainly see maction as an attempt to make MathML interactive, which should be much more used.

    • <maction> provides a way to storing precomputed "alternative representations" in presentation MathML (the children) which can then be used in many ways (including JS). I agree that the semantics element could also be used instead for this aspect.
    • (see @davidcarlisle's argument) non-JS environments.
  7. davidcarlisle commented on Mar 7, 2019

    @davidcarlisle
    Collaborator

    I think my preferred solution would be to keep maction in core but defined as to render the first child only, with the rest as if by css display:none

    That way there is a hook for moving interaction between web platform and other implementations of mathml.

    The full spec could make all actiontypes optional (already the case in mathml3) and can explicitly note that in an implementation of mathml core it is the responsibility of the page to implement any interaction via JavaScript.

    probably that would mean deprecating the selection attribute and instead putting the default selection first.

  8. kohlhase commented on Mar 7, 2019

    @kohlhase

    this is also what I would prefer.

  9. fred-wang commented on Mar 14, 2019

    @fred-wang
    Author

    OK, that makes sense. Just to be more slightly more accurate the proposal would be to:

    • Treat maction as an mrow for layout purpose.
    • Make the default display values of all but the first child display: none (it can be overridden by users via standard CSS).
  10. davidcarlisle commented on Mar 14, 2019

    @davidcarlisle
    Collaborator

    Yes @fred-wang I think that is all core needs here, thanks.

  11. added
    compatibility
    on Mar 20, 2019
  12. added
    need resolution
    on May 16, 2019
  13. fred-wang commented on Jun 4, 2019

    @fred-wang
    Author
  14. 5 remaining items

  15. removed
    need specification update
    on Jun 5, 2019
  16. added
    css / html5
    and removed
    need tests
    on Sep 17, 2019
  17. removed
    need polyfill
    on May 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    MathML 4MathML Corecompatibilitycss / html5

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions