Font format incorrect import in theme #29719
Labels
Fixed in 2.4.x
The issue has been fixed in 2.4-develop branch
Issue: Confirmed
Gate 3 Passed. Manual verification of the issue completed. Issue is confirmed
Issue: Format is valid
Gate 1 Passed. Automatic verification of issue format passed
Issue: Ready for Work
Gate 4. Acknowledged. Issue is added to backlog and ready for development
Priority: P3
May be fixed according to the position in the backlog.
Progress: done
Reported on 2.4.0
Indicates original Magento version for the Issue report.
Reproduced on 2.4.x
The issue has been reproduced on latest 2.4-develop branch
Severity: S3
Affects non-critical data or functionality and does not force users to employ a workaround.
Triage: Dev.Experience
Issue related to Developer Experience and needs help with Triage to Confirm or Reject it
Uh oh!
There was an error while loading. Please reload this page.
Preconditions:
Magento 2.4-develop
Default magento font import lib-font-face use type woff or woff2. In real case when user use another font type such as true type. Font import will work incorrect if add format truetype
Example in less define custom font
.lib-font-face( @family-name: 'Inter-Light', @font-path: '@{baseDir}fonts/Inter-Light', @font-format: 'ttf', @font-weight: normal, @font-style: normal, @font-display: auto );
will generate css font-face
@font-face { font-family: 'Inter-Light'; src: url('../fonts/Inter-Light.ttf') format('ttf'); font-weight: normal; font-style: normal; font-display: auto; }
format font src seem incorrect in the case truetype. Reference in this doc
https://developer.mozilla.org/en-US/docs/Web/CSS/@font-face
src: url('../fonts/Inter-Light.ttf') format('ttf') should be
src: url('../fonts/Inter-Light.ttf') format('truetype');
Steps to Reproduce:
Actual Result: ✖️
Font not render properly

styles-m.css render with font

Expected Result: ✔️
import



render styles-m.css
web font request
Proposed solution
--- Update mixin font with new type font argument in order import correct type
Please provide Severity assessment for the Issue as Reporter. This information will help during Confirmation and Issue triage processes.
The text was updated successfully, but these errors were encountered: