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: DLT-1915 add stylelint warning when using px or rem instead of tokens #509

Merged
merged 2 commits into from
Oct 1, 2024

Conversation

ninamarina
Copy link
Contributor

@ninamarina ninamarina commented Sep 26, 2024

feat: DLT-1915 add stylelint warning when using px or rem instead of tokens

🛠️ Type Of Change

These types will increment the version number on release:

  • Fix
  • Feature
  • Performance Improvement
  • Refactor

📖 Jira Ticket

DLT-1915

📖 Description

Adds a stylelint rule to detect the use of px or rem instead of tokens.
In the case of px there are two warnings, one suggesting the use of tokens, and another suggesting the use of rem if that is not posible.

💡 Context

We observed in the Adoption Audit that in some cases px values where used for spacing, sizing, typography instead of Dialtone tokens.

📝 Checklist

For all PRs:

  • I have ensured no private Dialpad links or info are in the code or pull request description (Dialtone is a public repo!).
  • I have reviewed my changes.
  • I have added all relevant documentation.
  • I have considered the performance impact of my change.

🔮 Next Steps

Enable the rule in Ubervoice once its released.

📷 Screenshots / GIFs

image

🔗 Sources

@ninamarina ninamarina changed the title feat: DLT-1915 add stylelint warning when using px or rem instead of … feat: DLT-1915 add stylelint warning when using px or rem instead of tokens Sep 26, 2024
@ninamarina ninamarina marked this pull request as ready for review September 26, 2024 17:03
Copy link

✔️ Deploy previews ready!
😎 Dialtone preview: https://dialtone.dialpad.com/deploy-previews/pr-509/
😎 Dialtone-vue 2 preview: https://dialtone.dialpad.com/vue/deploy-previews/pr-509/
😎 Dialtone-vue 3 the preview: https://dialtone.dialpad.com/vue3/deploy-previews/pr-509/

Copy link
Contributor

@braddialpad braddialpad left a comment

Choose a reason for hiding this comment

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

Thanks!

@ninamarina ninamarina merged commit 77212aa into staging Oct 1, 2024
8 checks passed
@ninamarina ninamarina deleted the add/stylelint-tokens branch October 1, 2024 19:17
juliodialpad pushed a commit that referenced this pull request Oct 7, 2024
# [9.78.0](dialtone/v9.77.0...dialtone/v9.78.0) (2024-10-07)

### Bug Fixes

* **Emoji Picker:** NO-JIRA refactor fix ref reactivity in vue2 ([#523](#523)) ([f164cad](f164cad))
* **Tokens:** NO-JIRA incorrect hsl for reference tokens ([#516](#516)) ([eb4e10e](eb4e10e))

### Features

* DLT-1915 add stylelint warning when using px or rem instead of tokens ([#509](#509)) ([77212aa](77212aa))
juliodialpad pushed a commit that referenced this pull request Oct 7, 2024
# [1.2.0](stylelint-plugin-dialtone/v1.1.0...stylelint-plugin-dialtone/v1.2.0) (2024-10-07)

### Features

* DLT-1915 add stylelint warning when using px or rem instead of tokens ([#509](#509)) ([77212aa](77212aa))
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.

2 participants