From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/29129 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: BPJ Newsgroups: gmane.text.pandoc Subject: Re: Singleton block construct with attributes? Date: Wed, 25 Aug 2021 18:37:56 +0200 Message-ID: References: <066d8f5e-ede0-4705-9f38-4add41cb7ff1n@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="000000000000f098cc05ca64df57" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="23549"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBCWMVYEK54FRB37DTGEQMGQEBCE3SWQ-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Wed Aug 25 18:38:10 2021 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-ed1-f61.google.com ([209.85.208.61]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1mIvuj-0005vu-5d for gtp-pandoc-discuss@m.gmane-mx.org; Wed, 25 Aug 2021 18:38:09 +0200 Original-Received: by mail-ed1-f61.google.com with SMTP id b8-20020a056402350800b003c5e3d4e2a7sf34180edd.2 for ; Wed, 25 Aug 2021 09:38:09 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1629909488; cv=pass; d=google.com; s=arc-20160816; b=uE1GWSmFSUvphQkrrvTrO25tzgUlNLxHKwlHNPcgyEjAEEWe/rzCuT7PEp9fFyiobE h2IWmkGI0Xa8oUswl1E1Rs5UxjeyAbhNdopjMMm5pJ4hwPALZcMHVhot22MwPpEK27lB RWbt9bdxKmg4+nfUhibZ2W1fLwHs04nCE5XiK/KhpTZIvmaveT5vymPFO4Y4ct9xCg4Y qUGq17Y3ewqdrrrhZRxjygVRkkTlH27IQSU1d8vTzUVfJq2GzqdmOEgjka7HXdIgVcES sqBAEBOVvolUiqdZeidT0ywcw8tdJTMjnJlo1KcgmySdMhq63eBHLd0Sho2qIzEMxCdW O9xQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:to:subject:message-id:date :from:in-reply-to:references:mime-version:sender:dkim-signature :dkim-signature; bh=tmfjpj1U83ThOME9wzuNPwctO9LA3K2dGqTUV077qBI=; b=NMLDodDJqbXWQKqhk8ZiXgQqnhdC9AhTtu0nujBfQYjNAuo8eIE5k6fka1lqzHJIQt QMRbkyapMclE1LL7W0Zaykjy7xROtBkue2szaW56q4ZBYqFFU6TSapirPklgqQT+X+gP FmuH4GWxSDYx9kTVGG6mGi1y/SUrOuQvcn/J0vR/GXugi6S2A1yaRzStOVlaw5hL48t6 +K+JIzK7FgdAZX13+b6Y7BKHCIFsrWRKyKlQNHn1CNsu7IKqJC7K6kA0Zwc4iTZik+ZS C8f+rRHrQ23pumxZE8CGMFbHdpjW6InzaagxC+EvzKnPjDKBFvI18g5zyVmjPyK5jCav XebA== ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UE4IC25d; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 2a00:1450:4864:20::229 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; h=sender:mime-version:references:in-reply-to:from:date:message-id :subject:to:x-original-sender:x-original-authentication-results :reply-to:precedence:mailing-list:list-id:list-post:list-help :list-archive:list-subscribe:list-unsubscribe; bh=tmfjpj1U83ThOME9wzuNPwctO9LA3K2dGqTUV077qBI=; b=YZym24qNQFna2C1Jw1gW4klKUb8fF5btcvqgEQj1KSO25kA4WL49Wfjho78vgA3c7g AEHhdu2gkDCRvf9n0DO6AXOfXNvsLq1eWJlen50aVJmQIBlt+snctr4OKzXwRkZBl+od CEGdhvgB2CTf2xj3vafWKFzlUFltunRDrcRFkq00dr4NIHcCWn/P8lj2Qea9j2cZEbe3 NzLqYuw4o7Qcb2ZFDIbk27G7xMZfDGzJsPHzWNKFeBWJ5atEhVyvHbZ2lk3Rb6O5Tklq A9qP79/yJeXFU0Jc3lh14qa92mtHjAbdoR90UN9KBHnYEEkBHP7Bl5HdzfNJljUKfAYd DRZg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :x-original-sender:x-original-authentication-results:reply-to :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=tmfjpj1U83ThOME9wzuNPwctO9LA3K2dGqTUV077qBI=; b=hyc35bMnbi3eeSEq3MN4rQID4IUBAVdhXbBZmUGmnbvkwwwOktA5/5ZQHR7iezbVGw yxaLDk437WriUUAINJT1einhMFc0rsKfNUCvZClFdYcFbEi8bfwk7nVp5PtCDSsa3aJU eFonk5KO68d+sCgau6DqfMY8RaxTW1jmjlTJgqFQMdHgLqIS/BVSsSYnYfiEXBMTitgx gZdjyDF1nK96HsABlUZoDhdmspffRxeI7J5L8wgeCq9QOn3DbxrbYq+NEptzrd0GlUp5 I8PiYZtzZw2CSUdccOOi7LA4rLcfByFrJLywPc+lnZ9mA5VZaxY8eleVPpnLA3X8pwqt 8ZmQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=sender:x-gm-message-state:mime-version:references:in-reply-to:from :date:message-id:subject:to:x-original-sender :x-original-authentication-results:reply-to:precedence:mailing-list :list-id:x-spam-checked-in-group:list-post:list-help:list-archive :list-subscribe:list-unsubscribe; bh=tmfjpj1U83ThOME9wzuNPwctO9LA3K2dGqTUV077qBI=; b=ltaefitdw+i74kFElf+3FBZwoVCQGARBaEOSFIneLupedTLJsbf/5hu2I2YxtZozTM 2IYiZY17KI8lt1SH2eALRje4eecofRA6wNsxUduaqycic4v7e6eqT7o6muf2y5GpF5Kq exwqV4sT1hMfn9OuHWfrb25qAcSSkNgoiduB+sgQZOMwyE2Yf4C9j4h6M1b75x/VBZk7 xXhpBXx59Olg8WyoQcCdWvwLjTlZ5Be1e+cWOnJsvlVgwHuHAem3wkN3jypgPwXEnJVC tP4M2kY6Kqx2BFUpeHbtew1dyalSWl4RK0JHOF73B4SUnamYLFNBecAwpsLMWWdIH65F wV+w== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: AOAM532F7+7OrX+LB/wDMSsdKVMO0WUQAXZgt7gWUMde0DoQRsi8bO/h xrM1GCCleXcpCtqm48hOoi4= X-Google-Smtp-Source: ABdhPJxImvL6QoUpLP/X1PxdinOlcy1/mJSw9UlgrLG8081adVqm6pTRA7s9mqnaKF06PQysOb4r9Q== X-Received: by 2002:a05:6402:b5b:: with SMTP id bx27mr50430405edb.229.1629909488897; Wed, 25 Aug 2021 09:38:08 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:aa7:c348:: with SMTP id j8ls3046624edr.0.gmail; Wed, 25 Aug 2021 09:38:06 -0700 (PDT) X-Received: by 2002:a05:6402:c05:: with SMTP id co5mr7918585edb.41.1629909486574; Wed, 25 Aug 2021 09:38:06 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1629909486; cv=none; d=google.com; s=arc-20160816; b=zF3dY9KfNfaZm4ac0jMfBRwwZvnKLtiF4Awmwj6taUMtzvEFDjK+Ru/IXZiEBDGOD0 oh/wfIU5D47l3exBC+kWMmiFfxmwpW/PWqz+3Ebow7ZM0N1W7COwHYb9Xnhg3ya/Wl3i JwE2oicLDX+a4VgUUD35Id/48zpsDKZjZgXdSk7NHPQ4IPH4DdV2yXtIG4GbWgsanTw9 rnDe4bvAy7q23hVKgh6CRPFFGquJPBqIB27HbE6BnnvG36yVql15d7QnfIaGmUdDvkua AXy+rjnEG4efrE3J0awnvQ61vw9UXFeCG6U+CWJsfcwQCF5OUZu3/F6hkIbnb4/r42De TCGQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=PxL+50XOKv2iTC2hhzRtjPSyvooqcFnOqNPcj+DdyGc=; b=pkisPORTE4T9bVarhpma13AQC59364+ubboWVvMHSMSg8tsWSKm0hqntjEYxSyD0QX +KkyxdyTkwhOYR1Nq1RmzuMhZA4A5KdKNPisFSn1tqTpZCeQE1yz9lHx7CqUrAQmG9BZ zdP/Ioy7sxX5hePGNqjWZKvt1vHQ25eIOtB+oykl0Cnvj5EMUkeMzsmHMqZNFh0IkAYY vxzQXZphQUpwzbcAEyqB3X0lp3z9lq1DkCDeeQrE848csm0IepEKiPg49C3a+vp/QeL0 jn2pXiGAVeN30vS2vKlonuAxIuhZxhtz/b53SJbnHLiilskGjjtYiABNDOs25l+1KEtn sVIg== ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UE4IC25d; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 2a00:1450:4864:20::229 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Original-Received: from mail-lj1-x229.google.com (mail-lj1-x229.google.com. [2a00:1450:4864:20::229]) by gmr-mx.google.com with ESMTPS id co13si37279edb.3.2021.08.25.09.38.06 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Wed, 25 Aug 2021 09:38:06 -0700 (PDT) Received-SPF: pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 2a00:1450:4864:20::229 as permitted sender) client-ip=2a00:1450:4864:20::229; Original-Received: by mail-lj1-x229.google.com with SMTP id q21so44594687ljj.6 for ; Wed, 25 Aug 2021 09:38:06 -0700 (PDT) X-Received: by 2002:a2e:2417:: with SMTP id k23mr37044138ljk.256.1629909486179; Wed, 25 Aug 2021 09:38:06 -0700 (PDT) In-Reply-To: X-Original-Sender: melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=UE4IC25d; spf=pass (google.com: domain of melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org designates 2a00:1450:4864:20::229 as permitted sender) smtp.mailfrom=melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com 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:29129 Archived-At: --000000000000f098cc05ca64df57 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Oops. Typo on the last if line! Den ons 25 aug. 2021 18:33BPJ skrev: > When I need a marker like this I use a code span, like > > `--pause` > > ``````lua > -- Look for a paragraph > function Para (para) > -- With only one child > if 1 =3D=3D #para.content then > local child =3D para.content[1] > -- Which is a code span > if 'Code' =3D=3D child.type then > -- Ignore it if it has a class .code, i.e. `--pause` is a marker, b= ut > -- `--pause`{.code} is "actual" code. > if child.classes:includes('code') then > return nil > end > -- If it is the marker return some block content > if '--pauae' =3D=3D child.text then > return whatever() > end > end > end > return nil > end > `````` > > > Den ons 25 aug. 2021 10:24Axel Rauschmayer skrev: > >> For two filters of mine, I=E2=80=99d like to use a singleton block const= ruct that >> triggers them via a class. I was considering using a horizontal rule: >> >> ---{.pause} >> >> Alas, that doesn=E2=80=99t work. What is a good alternative? If there is= n=E2=80=99t any, >> I can use the following syntax, but I=E2=80=99d prefer something that fi= ts into a >> single line. >> >> ::: pause >> ::: >> >> -- >> You received this message because you are subscribed to the Google Group= s >> "pandoc-discuss" group. >> To unsubscribe from this group and stop receiving emails from it, send a= n >> email 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/066d8f5e-ede0-4705-9f38= -4add41cb7ff1n%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/CADAJKhD-nf_TwJ8ojdN2zDhAc%2Bq-7svG713%3D2ZMDzeG4e9Edvg%40ma= il.gmail.com. --000000000000f098cc05ca64df57 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Oops. Typo on the last if line!

Den ons 25 aug. 2021 18:33= BPJ <melroch-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skre= v:
When I need a marker like this I use a code span, like

=C2=A0 =C2=A0 `--pause`

``````lua
-- Look= for a paragraph
function Para (para)
=C2=A0 -- With only one child
=C2=A0 if 1 = =3D=3D #para.content then
=C2=A0 =C2=A0 local child = =3D para.content[1]
=C2=A0 =C2=A0 -- Which is a code= span
=C2=A0 =C2=A0 if 'Code' =3D=3D child.t= ype then
=C2=A0 =C2=A0 =C2=A0 -- Ignore it if it has= a class .code, i.e. `--pause` is a marker, but
=C2= =A0 =C2=A0 =C2=A0 -- `--pause`{.code} is "actual" code.
=C2=A0 =C2=A0 =C2=A0 if child.classes:includes('code'= ) then
=C2=A0 =C2=A0 =C2=A0 =C2=A0 return nil
<= div dir=3D"auto">=C2=A0 =C2=A0 =C2=A0 end
=C2=A0 =C2= =A0 =C2=A0 -- If it is the marker return some block content
=C2=A0 =C2=A0 =C2=A0 if '--pauae' =3D=3D child.text then<= /div>
=C2=A0 =C2=A0 =C2=A0 =C2=A0 return whatever()
<= div dir=3D"auto">=C2=A0 =C2=A0 =C2=A0 end
=C2=A0 =C2= =A0 end
=C2=A0 end
=C2=A0 ret= urn nil
end
``````


Den ons 25 aug. 2021 10:24Axel Rauschmayer <rausc= hma-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> skrev:
For tw= o filters of mine, I=E2=80=99d like to use a singleton block construct that= triggers them via a class. I was considering using a horizontal rule:
=
---{.pause}

=
Alas, that doesn=E2=80=99t work. What is a good alternative? If = there isn=E2=80=99t any, I can use the following syntax, but I=E2=80=99d pr= efer something that fits into a single line.

::: pause
:::

--
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 pandoc-discuss+unsubscribe@goo= glegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/0= 66d8f5e-ede0-4705-9f38-4add41cb7ff1n%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://gro= ups.google.com/d/msgid/pandoc-discuss/CADAJKhD-nf_TwJ8ojdN2zDhAc%2Bq-7svG71= 3%3D2ZMDzeG4e9Edvg%40mail.gmail.com.
--000000000000f098cc05ca64df57--