Opened 5 months ago
Last modified 2 months ago
#60716 new enhancement
Font Library: Replace error message "A font face matching those settings already exists" with notice
Reported by: |
|
Owned by: | |
---|---|---|---|
Milestone: | 6.7 | Priority: | normal |
Severity: | normal | Version: | 6.5 |
Component: | Editor | Keywords: | has-screenshots needs-patch needs-design-feedback |
Focuses: | Cc: |
Description
If the font already exists, it is not an error, and should not scare the user.
Attachments (3)
Change History (16)
#2
@
5 months ago
- Keywords has-screenshots added
Hi @oglekler
I can replicate the mentioned issue on my local where I tried to install the existing font family.
This should not be displayed as an error but it should be prompted as a warning I believe.
Bug Reproduction Report:
Reproduction Report
Description
This report validates whether the issue can be reproduced.
Environment
- WordPress: 6.5-RC2
- PHP: 8.1.23
- Server: nginx/1.16.0
- Database: mysqli (Server: 8.0.16 / Client: mysqlnd 8.1.23)
- Browser: Chrome 122.0.0.0
- OS: macOS
- Theme: Twenty Twenty-Four 1.0
- MU Plugins: None activated
- Plugins:
- Test Reports 1.1.0
- WordPress Beta Tester 3.5.5
Actual Results
- ✅ Error condition occurs (reproduced).
Additional Notes
N/A
Supplemental Artifacts
Please check the attached screenshot here.
#3
@
5 months ago
- Summary changed from Font Library:Replace error message "A font face matching those settings already exists" with notice to Font Library: Replace error message "A font face matching those settings already exists" with notice
- Version set to trunk
#4
@
5 months ago
- Component changed from General to Editor
- Milestone changed from Awaiting Review to 6.6
- Type changed from defect (bug) to enhancement
This ticket was mentioned in Slack in #core by jorbin. View the logs.
4 months ago
#7
@
4 months ago
- Keywords needs-design-feedback added
- Milestone changed from 6.5.1 to 6.6
I no longer think this makes sense for a minor release, so moving back to 6.6. Also would like the design team to weigh in.
#8
@
4 months ago
Hi @jorbin,
How about using a Notice with info
as status
?
Somewhat like (Note: For now we can skip the text appearing in image & update it later, once the UI is finalised 😇)
Also, as we are going to update the Font upload modal & the code change will be in edit-site package of Gutenberg repo, should I go ahead & create an issue on Gutenberg repo for this (if not already created).
Have already created a draft PR containing error bifurcation (into error/warning/info) logic. We can further update the logic/UI as per the discussion/feedbacks. 😉
#9
@
3 months ago
@joedolson what do you think about this notification? I assume it should look as all others and this can be related to #50442
#10
@
3 months ago
Is there already a standardized notification format in the block and site editor? I don't recall seeing one. Per the conversation on #50442, there are some translation problems with some of the labels we commonly use in English; e.g. 'Success', so the same decisions need to be made here.
But we should use the same basic model for notifications in both systems, so it's the same issue.
But I do agree that this notification should be purely informational. Is there a reason it's not informing the user which font matches those settings? I think it would be much more useful to the user if the notice was something like "[name of font face]" is already in your library with the same settings.
This ticket was mentioned in Slack in #core by oglekler. View the logs.
2 months ago
#12
@
2 months ago
@oglekler @joedolson
Is there already a standardized notification format in the block and site editor? I don't recall seeing one
Couldn't find one either.
For the ticket, we've following options:
- Update the error message only: If we want to modify only the error message it's a quick change in
WP_REST_Font_Faces_Controller
class and can be easily added.
- Update the error type to info: This would require a decent amount of changes and testing since there is no support for info/warning type of notification in the component.
And if we opt for 2nd option, with the first 6.6 beta being so close IMO the ticket should be punted to 6.7.
#60715 was marked as a duplicate.