From 16f9fa9281712bd316248ecee09b52fd0e62d5ff Mon Sep 17 00:00:00 2001 From: Estelle Weyl Date: Tue, 11 Jun 2024 12:12:11 -0700 Subject: [PATCH] 33505: tr parents (#33927) * 33505: tr parents Suggested fix for #33505 * Update files/en-us/web/html/element/tr/index.md Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> * new suggestion. * spaces * Apply suggestions from code review Co-authored-by: Chris Mills --------- Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> Co-authored-by: Chris Mills --- files/en-us/web/html/element/tr/index.md | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/files/en-us/web/html/element/tr/index.md b/files/en-us/web/html/element/tr/index.md index 39d729741924dcb..701c66b4d403609 100644 --- a/files/en-us/web/html/element/tr/index.md +++ b/files/en-us/web/html/element/tr/index.md @@ -41,8 +41,11 @@ The following attributes are deprecated and should not be used. They are documen ## Usage notes -- The `` may be placed as a direct child of its parent {{HTMLElement("table")}} element, but only if the `` has no child {{HTMLElement("tbody")}} elements, and only after any {{HTMLElement("caption")}}, {{HTMLElement("colgroup")}}, and {{HTMLElement("thead")}} elements. Otherwise, the parent must be a {{HTMLElement("thead")}}, {{HTMLElement("tbody")}}, or {{HTMLElement("tfoot")}} element. +- The `` element is valid as a child of a {{HTMLElement("thead")}}, {{HTMLElement("tbody")}}, or {{HTMLElement("tfoot")}} element only. +- If the `` is placed as a direct child of its parent {{HTMLElement("table")}} element, the `` parent is implied and browsers will add the `` to the markup. +- The implied `` parent is only supported if the `
` otherwise has no child `` elements, and only if the `` is included after any {{HTMLElement("caption")}}, {{HTMLElement("colgroup")}}, and `` elements. - The CSS pseudo-classes {{cssxref(":nth-of-type")}}, {{cssxref(":first-of-type")}}, and {{cssxref(":last-of-type")}} are often useful for selecting the desired set of rows and their data and header cells ({{HTMLElement("td")}} and {{HTMLElement("th")}} elements). +- When a `` is included as a direct child of the `
`, as the browser adds a `` to the markup, CSS selectors such as `table > tr` may not work as expected or at all. ## Examples