Skip to content

Bold text no longer displayed as bold #24835

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wolfbeast opened this issue May 21, 2023 · 8 comments
Closed

Bold text no longer displayed as bold #24835

wolfbeast opened this issue May 21, 2023 · 8 comments
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail type/bug

Comments

@wolfbeast
Copy link

Description

With one of the recent updates of our self-hosted Gitea (probably when moving to 1.19.3 from 1.18.*) some formatting no longer applies.
Most notably, headers and bold text is no longer rendered as such.

I checked the CSS involced and found:

b, strong, h1, h2, h3, h4, h5, h6 {
    font-weight: var(--font-weight-bold);
}
b, strong {
    font-weight: bolder;
}

It seems the --font-weight-bold value is not filled properly or set to a bad value.
This occurs in the Pale Moon web browser. It does not occur in Edge.

Gitea Version

1.19.3

Can you reproduce the bug on the Gitea demo site?

Yes

Log Gist

No response

Screenshots

https://repo.palemoon.org/MoonchildProductions/UXP/issues/2252#issuecomment-36448
Image1

Git Version

2.39.2, Wire Protocol Version 2 Enabled

Operating System

CentOS

How are you running Gitea?

x86_64 Linux binary downloaded from gitea.io

Database

MySQL

@wolfbeast wolfbeast changed the title Bold test no longer displayed as bold Bold text no longer displayed as bold May 21, 2023
@wxiaoguang
Copy link
Contributor

wxiaoguang commented May 21, 2023

I am 99.99% sure it's related to your browser & font system ....

Does #24305 help? (a test link https://codepen.io/silverwind/pen/jOeBmvj ) , ps: there is also a following PR #24827 to reset the bold value to 600 from 601.

@wxiaoguang wxiaoguang added the issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail label May 21, 2023
@wolfbeast
Copy link
Author

wolfbeast commented May 21, 2023

Yeah the test link gives inconsistent results.
It weirdly renders 600 slightly bolder (semi-bold) but 601 and 610 as if it's not bold ... o.O -- not sure what's going on with Segoe UI there...

Image1

700 is proper bold. IIRC that is also the weight I'd always had to use when menually setting these values in my web design way back when. having it at 600 would work on my system, obviously (Windows 10 22H2, Radeon graphics).
But.. why not just use the normal keywords instead of fine-tuning? font-weight: bold is a thing, you know :)

The linked issue doesn't really give a solution how to solve this in my installation though. I'd be happy to just set it to 600 or bold, respectively. How would I override this non-functional default?

@wxiaoguang
Copy link
Contributor

But.. why not just use the normal keywords instead of fine-tuning? font-weight: bold is a thing, you know :)

The context is here : #24305 (comment)

@wxiaoguang
Copy link
Contributor

The linked issue doesn't really give a solution how to solve this in my installation though. I'd be happy to just set it to 600 or bold, respectively. How would I override this non-functional default?

ps: there is also a following PR #24827 to reset the bold value to 600 from 601.

Here it is.

@wolfbeast
Copy link
Author

Thanks, but... how do I apply that to my system? I'm a binary user -- I tend to use it stock (since I had nightmares previously using custom templates)

@wxiaoguang
Copy link
Contributor

wxiaoguang commented May 21, 2023

After the PR gets merged and backported, you can use nightly build.

For "custom template", if you only use something like custom/templates/custom/header.tmpl to inject JS/CSS, there won't be any nightmare, because this file will never conflict with the builtin ones.

image

@wolfbeast
Copy link
Author

Thanks, I appreciate the help!

@wolfbeast
Copy link
Author

FTR I went the custom template route (not comfortable running a nightly on a pivotal production repo):

<style>
:root {
  --font-weight-bold: 600;
}
</style>

Which fixes the issue on my setup. I'm thinking this may be a quirk of the Segoe font specifically? Either way, since it's already addressed in the PR otherwise I'll just close this.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Jul 6, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
issue/needs-feedback For bugs, we need more details. For features, the feature must be described in more detail type/bug
Projects
None yet
Development

No branches or pull requests

2 participants