From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/29352 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Pranesh Prakash Newsgroups: gmane.text.pandoc Subject: Re: revealjs background and self contained not working anymore Date: Thu, 7 Oct 2021 21:58:48 -0700 (PDT) Message-ID: References: <80a3d759-3f29-44d8-9a43-5890dcf9b70en@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_476_1332841372.1633669128209" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="20249"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBDA2Z3PTWYIBBCNA76FAMGQELOHZKJY-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Fri Oct 08 06:58:52 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-ot1-f63.google.com ([209.85.210.63]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mYhy8-0005A2-5D for gtp-pandoc-discuss@m.gmane-mx.org; Fri, 08 Oct 2021 06:58:52 +0200 Original-Received: by mail-ot1-f63.google.com with SMTP id p26-20020a9d4e1a000000b0054d847be7aasf4802142otf.7 for ; Thu, 07 Oct 2021 21:58:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; h=sender:date:from:to:message-id:in-reply-to:references:subject :mime-version:x-original-sender:reply-to:precedence:mailing-list :list-id:list-post:list-help:list-archive:list-subscribe :list-unsubscribe; bh=DsVjxf14PKaSIaoHueKui8hMwI/OSHnP6dompocS/Mk=; b=GqmnM+39CLPhVI3ibIwBJdMWo+m5H34YFvGzYHo2RCpJRZEmGkj3JTrJ/PH3BKQDof Z49h3AZRW0+QvwRqDdFURCmfnAqUVO5Wn9PgODwGhaz0mnb1H8evd2odUzNuFesPDa+S etquGWeI/iFrgDwPmtRrhPzrLphts6kJjxyyHk5t95jtw1GxwZCGxXZ3LjTIuKMf5TGo bTo61PyYBayyyBYnJk1LXZx9aG+mex7Jx8CxSQesh2AhYHlg0rIHO8caPWP9QrX9ueaP UhgGw/5I77iWPnmtKzpsYNE6n9yYeiHaGAU8iQugmz69RjVHmwuxOkIz3091fuZhSpzH zwdw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=date:from:to:message-id:in-reply-to:references:subject:mime-version :x-original-sender:reply-to:precedence:mailing-list:list-id :list-post:list-help:list-archive:list-subscribe:list-unsubscribe; bh=DsVjxf14PKaSIaoHueKui8hMwI/OSHnP6dompocS/Mk=; b=db/6ey0ft/sJ7qDkcTeIJwF1Rrkn0y4yF6bvsFYgn4jc4+/rJPLRwpLWMOnpCLe471 o82n2C6Hq4bWWx4aKmAZz9ypCgCPami7K20tKdFakhPoNDbatZvrBa9B+w3/rO9avkdA pxjvQgcKvoePhK+5bVXWVsYRltaiiaAtJ6nb8MtSTMGgkIO6LZnJ4fJTes201hNv1UNu YHSOBoeYRfoaKhIIrnFi36O7PUjBM//kkpLHJTNmDOlgr3ZgvMToaYPHhd+oJTl86Tk5 yMbuUmy5+OXp9SyC+zcFXOdviVcsH7ci7jxK2dSBmoKouLG0RDIMwD5l4iZVyKmdV6f1 AlHw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=sender:x-gm-message-state:date:from:to:message-id:in-reply-to :references:subject:mime-version:x-original-sender:reply-to :precedence:mailing-list:list-id:x-spam-checked-in-group:list-post :list-help:list-archive:list-subscribe:list-unsubscribe; bh=DsVjxf14PKaSIaoHueKui8hMwI/OSHnP6dompocS/Mk=; b=Yz/1H3HZUh3cw29MIpV3FNShhNijW25Zcb0b088Vbd5JbkDz+w67Num6/lFfQO+bE3 /e+ItsOZ76ZbQObTEgIyfyN1FLfLbzkK2Gv0JDL39/RnHkmjLF0bXaXaOm/TgiMg229K +ZNaR5QeFihvFlDW/qS9ZbhYz2I32AIBRyxHMMmVu0Jexq076wZao0c5ObgWs4ggBvUs UfZZws2vXxshOKkVVrPixtUGufKaC5//+4C/4VJTSAKMiaDI/vvcmIX37G9Fz2yYQiCw /6qrop8rr3D9il9mwFusElr7Iq3p42qKOahk+t3B3lWOQaBGWhi7R30E+zfNn4ZwMfiM t2sA== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM531/AXnhOT75Tw/2Iu6bgXL5Zu8e8fkyQ1seFKjg1kXfY/ht75EM qC51NZFmxNElDN35ozo3SzQ= X-Google-Smtp-Source: ABdhPJwXBAdvgOujNBU1NgsTctRucctCYYgFJ+eNkcmH6vIedjEuSZq0EZ12wolxTyZrNe10hWtluQ== X-Received: by 2002:aca:1c05:: with SMTP id c5mr3890237oic.165.1633669130483; Thu, 07 Oct 2021 21:58:50 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a05:6830:31bb:: with SMTP id q27ls658270ots.11.gmail; Thu, 07 Oct 2021 21:58:49 -0700 (PDT) X-Received: by 2002:a05:6830:314d:: with SMTP id c13mr6773090ots.90.1633669128851; Thu, 07 Oct 2021 21:58:48 -0700 (PDT) In-Reply-To: X-Original-Sender: the.solipsist-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:29352 Archived-At: ------=_Part_476_1332841372.1633669128209 Content-Type: multipart/alternative; boundary="----=_Part_477_1467004167.1633669128209" ------=_Part_477_1467004167.1633669128209 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable For the record, this issue has been fixed upstream, thanks to Christophe=20 and Hakim: https://github.com/fab4100/reveal.js/commit/3e0b68ea80e3c123def3182ecb183fe= bafae8961 On Tuesday, 28 September, 2021 at 10:36:04 pm UTC+5:30 John MacFarlane=20 wrote: > > Looking at the HTML using the browser's Inspect feature, I > see that reveal.js is adding a div devoted to backgrounds, > which uses a background-image-hash attribute. This may be > constructed improperly for data URIs; anyway, this is one > thing to investigate here. > > John MacFarlane writes: > > > Not sure what is happening here, but yes, an issue on the tracker > > would be welcome. > > > > I note also that because the data-background-image attribute > > is retained on the h1 element as well as being propagated to > > the section element, we get two copies of the encoded image. > > That is bad. See also https://github.com/jgm/pandoc/issues/5965 > > > > > > christophe dervieux writes: > > > >> Hello,=20 > >> > >> Here is a reproducible example of the issue > >> > >> curl --output background.jpg -L ' > https://unsplash.com/photos/8OyKWQgBsKQ/download?force=3Dtrue&w=3D1920' > >> > >> echo "# Slide {data-background-image=3D'background.jpg'}" > slide.md > >> echo "" >> slide.md > >> echo "Content" >> slide.md > >> > >> # Not self contained=20 > >> pandoc -t revealjs -s -o slide.html --metadata title=3D"test" slide.md > >> > >> # Self contained > >> pandoc -t revealjs --self-contained -o slide-self-contained.html=20 > --metadata title=3D"test" slide.md > >> > >> When using self-contained, the background image is no more working.=20 > Pandoc=20 > >> encodes to data: but it seems reveal.js does not know how to handle it= .=20 > It=20 > >> split the encoded data: in two url component. > >> > >> It seems like a change in reveal 4 as using the same slide.md file wit= h=20 > >> different version seems to break.=20 > >> > >> What I tried:=20 > >> > >> - Pandoc 2.9.2.1 : last one compatible with reveal.js 3 I believe > >>=20 > >> pandoc.exe -t revealjs --self-contained -o slide-self-contained.html= =20 > --metadata title=3D"test" -V revealjs-url=3Dhttps://unpkg.com/reveal.js@3= /=20 > slide.md > >>=20 > >> Works as expected=20 > >> - Pandoc 2.10: First to use reveal.js 4 > >>=20 > >> pandoc.exe -t revealjs --self-contained -o slide-self-contained.html= =20 > --metadata title=3D"test" -V revealjs-url=3Dhttps://unpkg.com/reveal.js@4= /=20 > slide.md > >>=20 > >>=20 > >> So it seems that something broke when upgrading.=20 > >> > >> Is this a known issue ? > >> Should I open an issue in Pandoc to track ? I believe this could be=20 > >> something in reveal.js not handling correctly encoded data: field. > >> > >> MANUAL still says ( > >> https://pandoc.org/MANUAL.html#background-in-reveal.js-and-beamer) > >> > >> Background images can be added to self-contained reveal.js slideshows= =20 > and=20 > >> to beamer slideshows. > >> > >> But maybe self-contained and revealjs does not work well.=20 > >> > >> Thank you > >> =E2=80=8B > >> > >> --=20 > >> You received this message because you are subscribed to the Google=20 > Groups "pandoc-discuss" group. > >> To unsubscribe from this group and stop receiving emails from it, send= =20 > an email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > >> To view this discussion on the web visit=20 > https://groups.google.com/d/msgid/pandoc-discuss/80a3d759-3f29-44d8-9a43-= 5890dcf9b70en%40googlegroups.com > . > --=20 You received this message because you are subscribed to the Google Groups "= pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an e= mail to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/= pandoc-discuss/f09ffb5b-eff9-451b-aeba-c45b1d456435n%40googlegroups.com. ------=_Part_477_1467004167.1633669128209 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable For the record, this issue has been fixed upstream, thanks to Christophe an= d Hakim:
https://github.com/fab4100/reveal.js/commit/3e0b68ea80e3c123de= f3182ecb183febafae8961

On Tuesday, 28 September, 2021 at 10:36:04 pm UT= C+5:30 John MacFarlane wrote:

Looking at the HTML using the browser's Inspect feature, I
see that reveal.js is adding a div devoted to backgrounds,
which uses a background-image-hash attribute. This may be
constructed improperly for data URIs; anyway, this is one
thing to investigate here.

John MacFarlane <j...@ber= keley.edu> writes:

> Not sure what is happening here, but yes, an issue on the tracker
> would be welcome.
>
> I note also that because the data-background-image attribute
> is retained on the h1 element as well as being propagated to
> the section element, we get two copies of the encoded image.
> That is bad. See also https://github.com/jgm/pandoc/issues/5965
>
>
> christophe dervieux <christoph...-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> writes:
>
>> Hello,=20
>>
>> Here is a reproducible example of the issue
>>
>> curl --output background.jpg -L 'https://unsplash.com/photos/8OyKWQgBsKQ/dow= nload?force=3Dtrue&w=3D1920'
>>
>> echo "# Slide {data-background-image=3D'background.jp= g'}" > slide.md
>> echo "" >> slide.md
>> echo "Content" >> slide.md
>>
>> # Not self contained=20
>> pandoc -t revealjs -s -o slide.html --metadata title=3D"t= est" slide.md
>>
>> # Self contained
>> pandoc -t revealjs --self-contained -o slide-self-contained.ht= ml --metadata title=3D"test" slide.md
>>
>> When using self-contained, the background image is no more wor= king. Pandoc=20
>> encodes to data: but it seems reveal.js does not know how to h= andle it. It=20
>> split the encoded data: in two url component.
>>
>> It seems like a change in reveal 4 as using the same slide.md = file with=20
>> different version seems to break.=20
>>
>> What I tried:=20
>>
>> - Pandoc 2.9.2.1 : last one compatible with reveal.js 3 I b= elieve
>> =20
>> pandoc.exe -t revealjs --self-contained -o slide-self-cont= ained.html --metadata title=3D"test" -V revealjs-url=3Dhttps://unpkg.com/reveal.js@3/ slid= e.md
>> =20
>> Works as expected=20
>> - Pandoc 2.10: First to use reveal.js 4
>> =20
>> pandoc.exe -t revealjs --self-contained -o slide-self-con= tained.html --metadata title=3D"test" -V revealjs-url=3Dhttps://unpkg.com/reveal.js@4/ s= lide.md
>> =20
>> =20
>> So it seems that something broke when upgrading.=20
>>
>> Is this a known issue ?
>> Should I open an issue in Pandoc to track ? I believe this cou= ld be=20
>> something in reveal.js not handling correctly encoded data: fi= eld.
>>
>> MANUAL still says (
>> https://pandoc.org/= MANUAL.html#background-in-reveal.js-and-beamer)
>>
>> Background images can be added to self-contained reveal.js sli= deshows and=20
>> to beamer slideshows.
>>
>> But maybe self-contained and revealjs does not work well.=20
>>
>> Thank you
>> =E2=80=8B
>>
>> --=20
>> You received this message because you are subscribed to the Go= ogle Groups "pandoc-discuss" group.
>> To unsubscribe from this group and stop receiving emails from = it, send an email to pandoc-disc= us...-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
>> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss= /80a3d759-3f29-44d8-9a43-5890dcf9b70en%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/f09ffb5b-eff9-451b-aeba-c45b1d456435n%40googlegroups.= com.
------=_Part_477_1467004167.1633669128209-- ------=_Part_476_1332841372.1633669128209--