Fix Themes v3 not working on Safari #3185

Closed
tusooa wants to merge 0 commits from gitlab-mr-iid-1918 into develop
Owner

Changes

image

Basically use <style> elements to replace document.adoptedStyleSheets if it is not available.

Note that this means that we are not able to use the advantage of the separation between eager and lazy styles.

In Safari I am also unable to clone the <style> element and keep its sheet property at the same time, so the style is modified in place.

Closes #1319

<!-- Feel free to submit merge requests that are work-in-progress, but mark them as Draft: or WIP:. Merge requests that have Draft or WIP status will not be merged and have less chances of being reviewed, but you can still ask people to take a look if you need advice. --> # Changes ![image](/attachments/229b5b39-2ca8-42e7-a832-a93b5a3ed1b4) Basically use `<style>` elements to replace `document.adoptedStyleSheets` if it is not available. Note that this means that we are not able to use the advantage of the separation between eager and lazy styles. In Safari I am also unable to clone the `<style>` element and keep its `sheet` property at the same time, so the style is modified in place. Closes #1319 <!-- List what your merge request changes and how --> <!-- Try to not to break existing behavior, if your changes do break existing behavior make it configurable to toggle between old behavior and new. Which one should be default is up to discussion. --> <!-- If your merge request resolves some issue link it like so: "Closes #99999" --> <!-- If merge request adds some new feature that depends on backend: 1. Make sure it gracefully degrades if backend hasn't been updated to support the feature, we try to make PleromaFE compatible with older versions of BE so that people can still update frontend safely without updating backend since it's costly and much riskier. 2. Link related BE merge request here --> <!-- Screenshots are welcome -->
284 KiB

Pull request closed

Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
pleroma/pleroma-fe!3185
No description provided.