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

Feat(variables-scss): Introduce export to javascript #DS-1437 #1656

Merged
merged 4 commits into from
Sep 26, 2024

Conversation

curdaj
Copy link
Contributor

@curdaj curdaj commented Sep 20, 2024

  • Add global index files
  • Add formatting of js output
  • Add functionality for exludedGroups (for other file)

@crishpeen points:

  • @themes - please add a comment noting which theme is default. It can be basically anywhere in the file
  • @global - please add empty line to the end of the file
  • everywhere if the value is 0px, please remove the units
  • in scss and js add comma after line-height in typography
  • in js prettier expects spaces instead of tabs
  • in js some objects can be simplified eg. focusRing: focusRing, -> focusRing,

Thing out of the scope will be solve in DS-1486

  • gradients and shadows color hexes can be shortened (in globals) - can be solved in the last issue (if you don't solve it here, add it to other issue, please)
  • can forwards be sorted in global/index.scss
  • in js eslint is failing on imports, probably not a problem of exporter, but I don't know what it is
  • I don't see all colors in theme-light-on-brand, i know not all colors are set, but even the set ones are not there

Description

Additional context

Issue reference

@github-actions github-actions bot added the feature New feature or request label Sep 20, 2024
Copy link

netlify bot commented Sep 20, 2024

Deploy Preview for spirit-design-system-storybook canceled.

Name Link
🔨 Latest commit 960986e
🔍 Latest deploy log https://app.netlify.com/sites/spirit-design-system-storybook/deploys/66f565c872d44200089970cb

Copy link

netlify bot commented Sep 20, 2024

Deploy Preview for spirit-design-system ready!

Name Link
🔨 Latest commit 960986e
🔍 Latest deploy log https://app.netlify.com/sites/spirit-design-system/deploys/66f565c7f41d1c00094ef817
😎 Deploy Preview https://deploy-preview-1656--spirit-design-system.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.
Lighthouse
Lighthouse
1 paths audited
Performance: 96 (no change from production)
Accessibility: 93 (no change from production)
Best Practices: 100 (no change from production)
SEO: 82 (no change from production)
PWA: -
View the detailed breakdown and full score reports

To edit notification comments on pull requests, go to your Netlify site configuration.

@coveralls
Copy link

coveralls commented Sep 20, 2024

Coverage Status

coverage: 78.732%. remained the same
when pulling 960986e on feat/ds-1437-export-into-js
into 7903f3c on main.

@curdaj curdaj marked this pull request as ready for review September 23, 2024 10:51
@curdaj curdaj changed the title 🚧 Feat(variables-scss): Introduce export to javascript #DS-1437 Feat(variables-scss): Introduce export to javascript #DS-1437 Sep 23, 2024
Copy link
Member

@crishpeen crishpeen left a comment

Choose a reason for hiding this comment

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

Please copy locally the exported files into the design-tokens package to see how it deals with the linters.

My points:

  • @themes - please add a comment noting which theme is default. It can be basically anywhere in the file
  • @global - please add empty line to the end of the file
  • everywhere if the value is 0px, please remove the units
  • gradients and shadows color hexes can be shortened (in globals) - can be solved in the last issue (if you don't solve it here, add it to other issue, please)
  • in scss add comma after line-height in typography
  • can forwards be sorted in global/index.scss
  • in js eslint is failing on imports, probably not a problem of exporter, but I don't know what it is
  • in js prettier expects spaces instead of tabs
  • in js some objects can be simplified eg. focusRing: focusRing, -> focusRing,
  • I don't see all colors in theme-light-on-brand, i know not all colors are set, but even the set ones are not there

@curdaj
Copy link
Contributor Author

curdaj commented Sep 25, 2024

Please copy locally the exported files into the design-tokens package to see how it deals with the linters.

My points:

  • @themes - please add a comment noting which theme is default. It can be basically anywhere in the file
  • @global - please add empty line to the end of the file
  • everywhere if the value is 0px, please remove the units
  • gradients and shadows color hexes can be shortened (in globals) - can be solved in the last issue (if you don't solve it here, add it to other issue, please)
  • in scss add comma after line-height in typography
  • can forwards be sorted in global/index.scss
  • in js eslint is failing on imports, probably not a problem of exporter, but I don't know what it is
  • in js prettier expects spaces instead of tabs
  • in js some objects can be simplified eg. focusRing: focusRing, -> focusRing,
  • I don't see all colors in theme-light-on-brand, i know not all colors are set, but even the set ones are not there

Thanks. I solved some things, some were outside the scope of this issue and I created a follow-up issue. See description above.

@literat
Copy link
Collaborator

literat commented Sep 25, 2024

One little closing remark: I would prefer normalizing the themes directory content to the same casing, like darkmode or dark-mode, Dark theme to dark-theme or darktheme and same for the Lightmode, please.

Otherwise it is looking good. Great Job. Thanks 👍

@curdaj
Copy link
Contributor Author

curdaj commented Sep 25, 2024

One little closing remark: I would prefer normalizing the themes directory content to the same casing, like darkmode or dark-mode, Dark theme to dark-theme or darktheme and same for the Lightmode, please.

Otherwise it is looking good. Great Job. Thanks 👍

Sorry, but I don't understand what you mean. Themes are loaded dynamically, including the name. So it depends on how it is named in the supernova.

@literat
Copy link
Collaborator

literat commented Sep 25, 2024

Sorry, but I don't understand what you mean. Themes are loaded dynamically, including the name. So it depends on how it is named in the supernova.

Ok, I see. So we need to standardize the naming of the themes or normalize them in JavaScript. Empty space can cause some troubles and I would like the directory structure to be normalized.

I will create an issue/long topic for this.

@curdaj curdaj force-pushed the feat/ds-1437-export-into-js branch 2 times, most recently from 554d4fe to 3e74fac Compare September 26, 2024 13:30
@curdaj curdaj merged commit afe5319 into main Sep 26, 2024
14 checks passed
@curdaj curdaj deleted the feat/ds-1437-export-into-js branch September 26, 2024 13:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants