-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
Migrate to static icons colours #32326
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
Conversation
e9a3e53 to
201e0c1
Compare
|
@CarlSchwan that should drastically remove some load as the svgController was getting pinged a lot for each page load! 🚀 |
057441d to
3eee3c4
Compare
I'm not sure how the SvgController works. It seems that before and after this PR there was zero network request against it even after a browser full refresh. Still, I can see significantly fewer DB queries when loading the cache and the scsscacher is cold, from 375 queries to 210 queries. Edit: I figured out how the iconcacher works, it basically inject the icons directly inside the CSS by using file_get_contents and then encoding it as base64. So that's why I didn't saw it in my apache logs. |
Ah right, we also did that, not always serving those via the svg Controller 🤔 |
3eee3c4 to
e3364f1
Compare
Signed-off-by: John Molakvoæ <[email protected]>
Signed-off-by: John Molakvoæ <[email protected]>
e3364f1 to
0c5ffe2
Compare
|
Tested a bit, one svg request is 10 DB queries. |
Signed-off-by: John Molakvoæ <[email protected]>
0c5ffe2 to
cb73fe2
Compare
nickvergessen
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
YOLO
|
Hey @skjnldsv
The Svg color api was a way to fetch internal icons (like those in the notifications list) and installed apps' icons in SVG format and optionally in a specified colour. I'm not sure if this API was ever used internally by Nextcloud server or other components (e.g. in relation to themes?). As you can see it's still mentioned in the latest developer guide. Because this API was public prior to being removed and might have had 3rd party integrations relying on it, it would be nice to offer an alternative if there isn't one already. Can you suggest a way to fetch said icons in SVG format (with or without specific colour) or know someone who could? A few example request URIs of old API: |

Implement a legacy compatibility layer for the svg icons colours
Refs: #32072 #32261