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

[IMPL] - added support for sass and scss stylesheet languages #4292

Open
wants to merge 28 commits into
base: main
Choose a base branch
from

Conversation

KronosDev-Pro
Copy link

  • better checking of stylesheets to be compiled
  • added support for sass and scss stylesheet languages
  • the stylesheets files are now copied to ".web/styles/" at compile time
  • relock poetry file for libsass deps
  • stylesheet compiler unit tests also check the contents of the file

All Submissions:

  • Have you followed the guidelines stated in CONTRIBUTING.md file?
  • Have you checked to ensure there aren't any other open Pull Requests for the desired changed?

Type of change

  • New feature (non-breaking change which adds functionality)
  • This change requires a documentation update

New Feature Submission:

  • Does your submission pass the tests?
  • Have you linted your code locally prior to submission?

Changes To Core Features:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your core changes, as applicable?
  • Have you successfully ran tests with your changes locally?

 - better checking of stylesheets to be compiled
 - added support for sass and scss stylesheet languages
 - the stylesheets files are now copied to ".web/styles/" at compile time
 - relock poetry file for libsass deps
 - stylesheet compiler unit tests also check the contents of the file
pyproject.toml Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
Copy link
Member

@adhami3310 adhami3310 left a comment

Choose a reason for hiding this comment

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

This looks much better now, a few nitpicks and we should be good to go !

reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
reflex/compiler/compiler.py Outdated Show resolved Hide resolved
@KronosDev-Pro
Copy link
Author

Sorry, that's why I can't see the error...

Unit tests, cp312
Unit tests, cp310

@KronosDev-Pro
Copy link
Author

KronosDev-Pro commented Nov 11, 2024

Units tests

python package check
cp39
+libsass
-libsass
cp310
+libsass
-libsass
cp311
+libsass
-libsass
cp312
+libsass
-libsass

@KronosDev-Pro
Copy link
Author

well, for the integration-node-latest / check_latest_node (3.12, 1, node), I don't know why he raises some errors

reflex/compiler/compiler.py Outdated Show resolved Hide resolved
@@ -165,7 +239,7 @@ def test_compile_stylesheets_exclude_tailwind(tmp_path, mocker):

assert compiler.compile_root_stylesheet(stylesheets) == (
str(Path(".web") / "styles" / "styles.css"),
"@import url('../public/styles.css'); \n",
"@import url('./styles.css'); \n",
Copy link
Member

Choose a reason for hiding this comment

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

are you sure this won't break anything?

Copy link
Author

Choose a reason for hiding this comment

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

I don't know where this could cause a problem, since all the supported stylesheet files in the app/assets directories and subdirectories are copied or compiled and saved in the .web/styles directory and no longer in the .web/public directories.

and also, I checked the second batch of the tests/integration group and the tests/integration/test_tailwind.py (which is the only one to have tests impacted by the changes) passed the tests without any errors, which is why I don't understand the error in the first batch of the tests/integration group.

 - better checking of stylesheets to be compiled
 - added support for sass and scss stylesheet languages
 - the stylesheets files are now copied to ".web/styles/" at compile time
 - relock poetry file for libsass deps
 - stylesheet compiler unit tests also check the contents of the file
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants