WordPress.org

Making WordPress.org

Opened 3 years ago

Last modified 6 months ago

#1077 reopened defect

Fix anchors in the bbPress & BuddyPress Codex theme so that anchors are not behind the toolbar

Reported by: netweb Owned by: dd32
Milestone: Priority: low
Component: buddypress.org Keywords: needs-patch
Cc:

Description

We should fix anchors in the Codex theme so that going to foo#bar puts bar at the top of the visible screen, rather than behind the toolbar

There's 3 suggested fixes for this mentioned in #BuddyPress on Slack:

https://wordpress.slack.com/archives/buddypress/p1433336799000531

Attachments (2)

1077.png (82.7 KB) - added by SergeyBiryukov 6 months ago.
1077.2.png (65.0 KB) - added by SergeyBiryukov 6 months ago.

Download all attachments as: .zip

Change History (15)

This ticket was mentioned in Slack in #buddypress by netweb. View the logs.


3 years ago

#2 @dd32
6 months ago

  • Owner set to dd32
  • Resolution set to fixed
  • Status changed from new to closed

In 6370:

BuddyPress.org & bbPress.org: Add a CSS :target block to make anchors scroll to the correct position.
For example: https://codex.buddypress.org/participate-and-contribute/#test-report-bugs

Fixes #1077.

#3 follow-up: @dd32
6 months ago

  • Keywords needs-patch removed

Ended up using the solution from https://www.itsupportguides.com/knowledge-base/tech-tips-tricks/how-to-offset-anchor-tag-link-using-css/ which seems to work pretty well.

I applied it globally to the bb-base theme rather than just the codex, as the only pages which don't use the overlayed header I could find didn't seem negatively affected by it being global.

#4 @dd32
6 months ago

In 6371:

BuddyPress.org & bbPress.org: Bump the CSS versions for cache-bust following r6370.

See #1077.

#5 in reply to: ↑ 3 @SergeyBiryukov
6 months ago

  • Resolution fixed deleted
  • Status changed from closed to reopened

Replying to dd32:

I applied it globally to the bb-base theme rather than just the codex, as the only pages which don't use the overlayed header I could find didn't seem negatively affected by it being global.

It does affect the forums in an unexpected way:

  1. Go to https://ru.wordpress.org/support/topic/помогите-найти-строку/#post-271548
  2. Try to select the text of the previous (one-line) post for quoting.
  3. The post cannot be selected, as it's covered by an invisible :target:before element.

Can we make that selector more specific, or the wporg-support theme should override it?

Last edited 6 months ago by SergeyBiryukov (previous) (diff)

@SergeyBiryukov
6 months ago

#6 @SergeyBiryukov
6 months ago

This also causes an issue with creating bbPress and BuddyPress Trac tickets, as reported by @netweb:

Steps to reproduce:

Now if you try to click Preview again, or Create Ticket nothing happens.

See 1077.2.png.

#7 @netweb
6 months ago

Thanks for tracking this bug down and adding the Trac info Sergey :+1:

This ticket was mentioned in Slack in #meta-tracdev by sergey. View the logs.


6 months ago

This ticket was mentioned in Slack in #buddypress by djpaul. View the logs.


6 months ago

#10 @netweb
6 months ago

In 6412:

BuddyPress/bbPress: Revert [6370]

The [6370] commit had some unexpected consequences of adding invisible :target:before elements on the bb's Trac and support forums.

See #1077.

#11 @netweb
6 months ago

In 6413:

BuddyPress/bbPress: Bump the CSS version for cache-bust following [6412].

See #1077.

#12 @netweb
6 months ago

Once I've some time to fix my #meta environment I'll refresh a patch for this, for now, I've reverted [6370] in [6412]

#13 @dd32
6 months ago

  • Keywords needs-patch added
  • Priority changed from normal to low
Note: See TracTickets for help on using tickets.