Skip to content
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

#8347 Fix custom document stylesheets nested stylesheet inheritance #8353

Merged
merged 9 commits into from Apr 29, 2024

Conversation

mnholtz
Copy link
Collaborator

@mnholtz mnholtz commented Apr 27, 2024

What does this PR do?

Demo

  • See playwright test
Screenshot 2024-04-26 at 5 39 41 PM

Checklist

  • Add jest or playwright tests and/or storybook stories
  • Designate a primary reviewer @BLoe

@mnholtz mnholtz requested a review from BLoe April 27, 2024 00:31
Copy link

codecov bot commented Apr 27, 2024

Codecov Report

Attention: Patch coverage is 91.66667% with 3 lines in your changes are missing coverage. Please review.

Project coverage is 73.53%. Comparing base (6608569) to head (213f50c).
Report is 1 commits behind head on main.

❗ Current head 213f50c differs from pull request most recent head 8340c87. Consider uploading reports for the commit 8340c87 to get more accurate results

Files Patch % Lines
src/components/StylesheetsContext.ts 91.30% 2 Missing ⚠️
src/bricks/renderers/documentView/DocumentView.tsx 85.71% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #8353      +/-   ##
==========================================
+ Coverage   73.50%   73.53%   +0.02%     
==========================================
  Files        1330     1331       +1     
  Lines       41142    41172      +30     
  Branches     7657     7662       +5     
==========================================
+ Hits        30241    30275      +34     
+ Misses      10901    10897       -4     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@mnholtz mnholtz changed the title #8347 Fix custom document stylesheets nested styling #8347 Fix custom document stylesheets nested stylesheet inheritance Apr 27, 2024
@twschiller twschiller added bug Something isn't working regression labels Apr 27, 2024
Copy link
Collaborator

@BLoe BLoe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looking good so far! Do we need to include EphemeralFormContent in these changes also? That one doesn't get nested in document view, but it was using the stylesheets hook to pull in the default/base styles, not sure if that's still needed or not.

@mnholtz mnholtz marked this pull request as ready for review April 29, 2024 17:36
Copy link

No loom links were found in the first post. Please add one there if you'd like to it to appear on Slack.

Do not edit this comment manually.

@mnholtz mnholtz merged commit b7aa3a0 into main Apr 29, 2024
22 checks passed
@mnholtz mnholtz deleted the bugfix/8347_broken_stylesheets branch April 29, 2024 19:33
twschiller pushed a commit that referenced this pull request Apr 30, 2024
…8353)

* introduce empty sidebarPanelTheme spec file

* introduce sidebar theme test

* add steps for opening the sidebar

* finish failing test with green assertions

* replace StylesheetsContext

* replace StylesheetsContext provider and hooks usage

* fix lint errors and add StylesheetsContext to strictnull

* replace ephemeralformcontent logic

* fix strict null error
@twschiller twschiller added this to the 1.8.13 milestone Apr 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working regression
Projects
None yet
Development

Successfully merging this pull request may close these issues.

CSS style sheets for embedded form not inherited from the parent document
4 participants