From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#71685: [PATCH] fix shr rendering in tables without tbody Date: Sat, 06 Jul 2024 10:36:31 +0300 Message-ID: <86h6d355vk.fsf@gnu.org> References: <65EAF7A2-697E-46E2-998C-AB99CC54E89C@gmail.com> Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="3757"; mail-complaints-to="usenet@ciao.gmane.io" Cc: 71685@debbugs.gnu.org To: JD Smith Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jul 06 09:37:18 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1sPzyw-0000n1-Bs for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 06 Jul 2024 09:37:18 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1sPzye-0006HA-15; Sat, 06 Jul 2024 03:37:00 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPzyc-0006Gi-LE for bug-gnu-emacs@gnu.org; Sat, 06 Jul 2024 03:36:58 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1sPzyc-0002Ax-Bw for bug-gnu-emacs@gnu.org; Sat, 06 Jul 2024 03:36:58 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1sPzyf-0005FV-Qg for bug-gnu-emacs@gnu.org; Sat, 06 Jul 2024 03:37:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 06 Jul 2024 07:37:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 71685 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 71685-submit@debbugs.gnu.org id=B71685.172025141520162 (code B ref 71685); Sat, 06 Jul 2024 07:37:01 +0000 Original-Received: (at 71685) by debbugs.gnu.org; 6 Jul 2024 07:36:55 +0000 Original-Received: from localhost ([127.0.0.1]:45486 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sPzyZ-0005F8-1Y for submit@debbugs.gnu.org; Sat, 06 Jul 2024 03:36:55 -0400 Original-Received: from eggs.gnu.org ([209.51.188.92]:59858) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1sPzyY-0005Eu-69 for 71685@debbugs.gnu.org; Sat, 06 Jul 2024 03:36:54 -0400 Original-Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1sPzyP-0001pO-CR; Sat, 06 Jul 2024 03:36:45 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=YE3MkwEAK37j70ogMZ9LmRlHHMxQPVMmybuM/hhIGsk=; b=XiN9J+LX2lG+ YtJx5sQdBpFl3sA0HWPaYgkeWo6SRiodlNydkEcyhmNnXwlmQU3NkE/LyUtv6xTY6q7vJ+r1c/iZR VuJMkHBqVq0CuiTaiYOi9S/4rrHctjzNcBjDQaN76pickIVq3QxAc4gB7gHR/IXStqClENamrwWBi EgIvsVoDgXI7+EfwBirXbop4/7szjvzXBVeresx/dF0JvQ9g3hlb9KYuvngFtR0FWFANEK3evhM3c 2wOmNSMqc6Ur9yFY2u1wgZoShWKpMLh/owfaM5XZDuXhc0c617TDjPvATH382koilJIZuTdtdKSYK aP/tbnahGvjUqKP9jRIr2w==; In-Reply-To: <65EAF7A2-697E-46E2-998C-AB99CC54E89C@gmail.com> (message from JD Smith on Thu, 20 Jun 2024 15:15:32 -0400) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:288464 Archived-At: > From: JD Smith > Date: Thu, 20 Jun 2024 15:15:32 -0400 > > It is very common for HTML tables to include a header () and/or footer () without using . Modern browsers simply supply an implicit .. around all the unparented rows in a table. `shr' does not handle this common case correctly. Below is an example with but not . It prints the header, but then subsumes it again inside the derived body, printing the header again in a single cell. > > The relevant function which should handle this is `shr--fix-tbody'. The included patch to this function simply avoids including `thead` and `tfoot` children in the implicit body. Thanks. I don't see any experts chiming in, so if you are confident in the patch, and it doesn't fail the existing tests, please install on the emacs-30 branch, and thanks. Bonus points for adding a test for this case.