-
Notifications
You must be signed in to change notification settings - Fork 2
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: design system implementation #51
base: main
Are you sure you want to change the base?
Conversation
9a8a508
to
211017d
Compare
@@ -0,0 +1,12 @@ | |||
import { createRequire } from "node:module"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually, we don't have any unit test now. Setup some stub tests for some of components
|
||
export default defineConfig({ | ||
test: { | ||
include: ["./test/**/*.test.ts"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Change to ./src/**/*.test.ts
because every component will have it's own test file
packages/web-components/package.json
Outdated
"eslint-plugin-react": "^7.36.1", | ||
"eslint-plugin-react-hooks": "^4.6.2", | ||
"eslint-plugin-storybook": "^0.11.1", | ||
"filesize": "^10.1.6", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm not sure, that every single dependency is used in the project. Check the dependencies and remove unused ones. You can use depcheck
, but be careful, it doesn't guarantee, that found packages are really useless
packages/web-components/package.json
Outdated
"@allurereport/web-commons": "workspace:*", | ||
"@preact/signals": "^1.3.0", | ||
"d3-shape": "^3.2.0", | ||
"i18next": "^24.0.2", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we talk about unnecessary dependencies, i18next
should be used on the end-project, not on the design system level. Focus on production dependencies
"license": "Apache-2.0", | ||
"author": "Qameta Software", | ||
"type": "module", | ||
"exports": { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add fonts
here and check, that the files can be imported in scss and js files
@@ -0,0 +1,26 @@ | |||
@mixin status-bg-and-text { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Think about the mixins vendoring because we actively use them in the applications
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For sure, we shouldn't compile them, it should be scss
files as is. Maybe, we can create set of css
classes, but it requires more changes than keeping the current approach
@@ -0,0 +1,71 @@ | |||
pre[class*="language-"], |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Convert the file to .scss
@@ -0,0 +1,21 @@ | |||
@font-face { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't include the file to the design system. Connect the fonts in the storybook, to see the proper view of the components and connect the fonts on the end-project level
@@ -0,0 +1,218 @@ | |||
:root { | |||
--font-family: "PTRootUIWebVF", ui-sans-serif, system-ui, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Add docs to the readme, which fonts we have to install to reach the proper view of the components. And add notes, that we distribute the fonts in the package
@@ -0,0 +1,5 @@ | |||
<svg viewBox="0 0 12 12" fill="none" xmlns="http://www.w3.org/2000/svg"> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It would be nice to notice icons in the readme too
211017d
to
6605b40
Compare
No description provided.