Suhail Singh <suhailsingh...@gmail.com> writes:

>> So, if we start allowing arbitrary attributes in more blocks, may as
>> well include specially handled attributes like :textarea.
>
> Yes, it is possible to address my concern while also extending support
> for non-HTML attributes like :textarea.  However, they still are
> distinct things.  For instance, it's possible that extending support for
> :textarea is considered a feature request (as opposed to a bug), and
> thus that support is added to the main branch as opposed to bugfix.

FYI, regardless how we categorize this (bug or feature), it is not for
bugfix because we are changing the existing behavior. Some users might
have #+ATTR_HTML being present and ignored. Not ignoring them, even if
it is a bug fix, is not acceptable for bugfix branch - it is not a
_trivial_ bug fix. So, it has to go on main.

>> Since we do not promise it anywhere, it is not necessarily a bug.
>
> We also don't, as far as I am aware, mention that support for
> #+ATTR_HTML is ONLY available for some AST nodes and NOT others.  Given
> that for the treatment of :textarea we are very clear on this point, the
> fact that we don't for #+ATTR_HTML suggested to me that this was a bug.
> I suppose it's debatable, however, whether it's a bug in the
> documentation or the code.  But, given most (all?) HTML elements support
> attributes, it would be odd if the intent of ox-html was to provide a
> way to support it via #+ATTR_HTML while simultaneously /intentionally/
> restricting its use to only a few nodes. Since `:textarea' is a "custom"
> attribute with special signifance, it makes sense that support for it
> may be limited in scope.
>
> Do you still consider this to be a feature request instead of a bug?

AFAIU, your main point is that you want the patch to land on bugfix. It
will not, regardless whether we add :textarea support or not.

Next, if you are not interested in adding :textarea support, it is
OK. Adding #+ATTR_HTML support for code blocks and fixed width elements
will still be a welcome improvement (I was just hoping to push you to
contribute a bit more ;))

Now, back to your original patch.
May you please factor out adding attributes into a separate function, so
that we avoid duplicating the code? And please announce the change in
the news - people aware of the current behavior might need to know about
the change.

-- 
Ihor Radchenko // yantar92,
Org mode contributor,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>

Reply via email to