From mboxrd@z Thu Jan 1 00:00:00 1970 From: Kaushal Modi Subject: Re: RFC: Proposal for an Org Special Block for ox-html Date: Thu, 24 May 2018 14:08:49 -0400 Message-ID: References: <87o9h56jdl.fsf@gmail.com> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000d7e8f2056cf78bd3" Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:34206) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fLufh-0003if-Ah for emacs-orgmode@gnu.org; Thu, 24 May 2018 14:09:06 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fLufg-0002U0-7Y for emacs-orgmode@gnu.org; Thu, 24 May 2018 14:09:05 -0400 Received: from mail-wr0-x22d.google.com ([2a00:1450:400c:c0c::22d]:33634) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fLuff-0002Tr-TX for emacs-orgmode@gnu.org; Thu, 24 May 2018 14:09:04 -0400 Received: by mail-wr0-x22d.google.com with SMTP id a15-v6so4757129wrm.0 for ; Thu, 24 May 2018 11:09:03 -0700 (PDT) In-Reply-To: <87o9h56jdl.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: "Emacs-orgmode" To: emacs-org list --000000000000d7e8f2056cf78bd3 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Aaron, Thanks for the feedback. On Thu, May 24, 2018 at 1:42 PM Aaron Ecay wrote: > Hi Kaushal, > > It seems like a good idea. My two comments are: > > - Remember that ox-html can export to HTML4, so the code would need to > detect that case and have a sensible fallback > Yes, I think that would need to be handle just as ox-html does now.. use div tags instead of details and summary tags. > - The approach of looking for =E2=80=9Cmagic=E2=80=9D strings in the cont= ents seems > hackish. What if the summary was treated as a caption? > I also feel like that's a hack, but seems quite robust and functional at least in my tests. The main reason to make summary part of details was to no impose a one-paragraph limit on summaries. Here's my pathological test for this feature: https://ox-hugo.scripter.co/test/posts/details-and-summary/ #+caption: Open for details > #+begin_details > Many details here. > #+end_details > > (Admittedly, the mismatch between =E2=80=9Ccaption=E2=80=9D and =E2=80=9C= summary=E2=80=9D is not ideal, > but caption is the only suitable keyword that the syntax gives us...). > I agree. caption doesn't go well with details.. looks like making a stew out of whatever's in the fridge. Hope that bad metaphor makes sense :) Another idea would be: > > #+begin_details > #+summary: Open for details. > Many details here. > #+end_details > HTML allows multi-paragraph summaries.. (see my test link above). Expanding on your idea.. what if we had another Special block with name summary? #+begin_details #+begin_summary Open for details More summary. #+end_summary Many details here. #+end_details It doesn't look as pretty as using the magic string "---", but it should work. But still not sure.. > Just food for thought... > I appreciate that. --=20 Kaushal Modi --000000000000d7e8f2056cf78bd3 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Hi Aaron,

Thanks for the fee= dback.

On Thu= , May 24, 2018 at 1:42 PM Aaron Ecay <aaronecay@gmail.com> wrote:
Hi Kaushal,

It seems like a good idea.=C2=A0 My two comments are:

- Remember that ox-html can export to HTML4, so the code would need to
=C2=A0 detect that case and have a sensible fallback
<= br>
Yes, I think that would need to be handle just as ox-html doe= s now.. use div tags instead of details and summary tags.
=C2= =A0
- The approach of looking for =E2=80=9Cmagic=E2=80=9D strings in the conten= ts seems
=C2=A0 hackish.=C2=A0 What if the summary was treated as a caption?

I also feel like that's a hack, but seems = quite robust and functional at least in my tests. The main reason to make s= ummary part of details was to no impose a one-paragraph limit on summaries.=

Here's my pathological test for this feature:= ht= tps://ox-hugo.scripter.co/test/posts/details-and-summary/
#+caption: Open for details
#+begin_details
Many details here.
#+end_details

(Admittedly, the mismatch between =E2=80=9Ccaption=E2=80=9D and =E2=80=9Csu= mmary=E2=80=9D is not ideal,
but caption is the only suitable keyword that the syntax gives us...).
<= /blockquote>

I agree. caption doesn't go well with d= etails.. looks like making a stew out of whatever's in the fridge. Hope= that bad metaphor makes sense :)

Another idea would be:

#+begin_details
#+summary: Open for details.
Many details here.
#+end_details

HTML allows multi-paragra= ph summaries.. (see my test link above). Expanding on your idea.. what if w= e had another Special block with name summary?

#+b= egin_details
#+begin_summary
Open for details

More summary.
#+end_summary
Many details here.
#+end_details

It doesn't look a= s pretty as using the magic string "---", but it should work.=C2= =A0 But still not sure..


=C2= =A0
Just food for thought...

I appreciate t= hat.
--

Kaushal Modi

--000000000000d7e8f2056cf78bd3--