@hashicorp/design-system-components 0.5.1 → 0.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +11 -0
- package/COMPONENT-CHECKLIST.md +73 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,16 @@
|
|
|
1
1
|
# @hashicorp/design-system-components
|
|
2
2
|
|
|
3
|
+
## 0.6.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#136](https://github.com/hashicorp/design-system/pull/136) [`bce712a7`](https://github.com/hashicorp/design-system/commit/bce712a7dc13615fa179b8c16791ac6cb8c37984) Thanks [@didoo](https://github.com/didoo)! - updated font-stack definitions in design tokens, will impact the visual aspect of all the components for certains combinations of OS/browser
|
|
8
|
+
|
|
9
|
+
### Patch Changes
|
|
10
|
+
|
|
11
|
+
- Updated dependencies [[`c17f142c`](https://github.com/hashicorp/design-system/commit/c17f142c0c938b471b696820d1fa440f62f7315b)]:
|
|
12
|
+
- @hashicorp/design-system-tokens@0.8.0
|
|
13
|
+
|
|
3
14
|
## 0.5.1
|
|
4
15
|
|
|
5
16
|
### Patch Changes
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
# New Component Checklist
|
|
2
|
+
|
|
3
|
+
This is the quest issue/engineering checklist for the COMPONENT_NAME Component. All new components will have their own feature branch, and any PR that adds an item from the checklist should target the feature branch, and not `main`.
|
|
4
|
+
|
|
5
|
+
## Pre-Flight Checklist
|
|
6
|
+
Update this list and these links as appropriate.
|
|
7
|
+
|
|
8
|
+
- [Component Requirement Document (CRD)](url_here): This file should exist before any code is written.
|
|
9
|
+
- [FIGMA Design](url_here): Since we are trying to align the component API naming with the same terms used in the Figma file, it is likely useful to have a fairly stable Figma design before we create a component; it should definitely be finalized before the component ships, however.
|
|
10
|
+
- [Design System Website](https://design-system-website.vercel.app/?path=/story/example-introduction--page) (storybook of storybooks): use for reference, to consider existing features that we might need to replicate in the component.
|
|
11
|
+
|
|
12
|
+
## Engineering Checklist
|
|
13
|
+
The engineering checklist has six parts: creating the feature branch, component template, component backing class, component style, tests, and documentation.
|
|
14
|
+
|
|
15
|
+
### Component Creation
|
|
16
|
+
|
|
17
|
+
- [ ] create new branch from main for the component.
|
|
18
|
+
- [ ] create new component
|
|
19
|
+
- `ember generate component hds/COMPONENT_NAME/index --gc` (the component won't need to be invoked with index, it's just to put all the files in the correct place)
|
|
20
|
+
- if it's a variation on a component, then `hds/COMPONENT_NAME/VARIATION` instead of `index`
|
|
21
|
+
- [ ] **component template**
|
|
22
|
+
- use semantic HTML
|
|
23
|
+
- the component should have a css class that is the same as the component (e.g. `hds/button` should have a class name of `hds-button` on the component, and additional CSS classes should start with this same class name.
|
|
24
|
+
- add `...attributes` unless doing so would be detrimental (e.g., a parent element and child element in the same component that both have ...attributes)
|
|
25
|
+
- [ ] **component class**
|
|
26
|
+
- use getters (vs template conditionals or constructors, if possible)
|
|
27
|
+
- write API comments in the JS doc way (copy from an existing DS component)
|
|
28
|
+
- use the same naming as the Figma file for the components API unless it conflicts with a pre-existing HTML attribute. If that is the case, document the difference in the comment.
|
|
29
|
+
- ensure that all existing functionality (from a Structure component) is accounted for in some way. If we are not providing existing functionality at all, it should be documented (along with the reason why). If we are providing temporary functionality, explain that it's temporary and why.
|
|
30
|
+
- check the [design system website](https://design-system-website.vercel.app/?path=/story/example-introduction--page) to see what kind of component functionality is being used across all products
|
|
31
|
+
- booleans should start with a verb (is/has/etc)
|
|
32
|
+
- assertion text should match the content style of the other components.
|
|
33
|
+
- goal is a terse invocation
|
|
34
|
+
- [ ] **component style**
|
|
35
|
+
- create `component/COMPONENT_NAME.scss` in `app/styles`
|
|
36
|
+
- add `@use` to `app/styles/@hashicorp/design-system-components.scss` (see existing code for precise syntax)
|
|
37
|
+
- use design tokens wherever possible, comment where they are not
|
|
38
|
+
- sizes should be in relative units
|
|
39
|
+
- line heights should be unitless
|
|
40
|
+
- [ ] **testing**
|
|
41
|
+
- [ ] test basic functionality
|
|
42
|
+
- [ ] test defaults
|
|
43
|
+
- [ ] try not to repeat tests (i.e., don't have to test all sizes, all colors, etc.)
|
|
44
|
+
- [ ] test all accessibility attributes
|
|
45
|
+
- [ ] **documentation**
|
|
46
|
+
- create component page `ember generate route components/COMPONENT_NAME --dummy`
|
|
47
|
+
- add link to `templates/index.hbs` page
|
|
48
|
+
- [ ] API docs
|
|
49
|
+
- [ ] Usage
|
|
50
|
+
- [ ] Accessibility
|
|
51
|
+
- [ ] Showcase
|
|
52
|
+
|
|
53
|
+
### Component Review
|
|
54
|
+
|
|
55
|
+
Pre-review request checks:
|
|
56
|
+
|
|
57
|
+
- [ ] run `yarn lint` and fix any issues (`yarn lint:hbs --fix` will resolve most issues)
|
|
58
|
+
- [ ] make sure all tests pass (`ember s` then visit /tests; or `ember t -s`)
|
|
59
|
+
- [ ] check for basic a11y on docs page:
|
|
60
|
+
- keyboard navigation
|
|
61
|
+
- logical DOM order
|
|
62
|
+
- zoom up to 400%
|
|
63
|
+
- color contrast
|
|
64
|
+
- (the axe-core browser plugin can run some basic tests and give immediate feedback)
|
|
65
|
+
- [ ] check page on browsers
|
|
66
|
+
- Chrome
|
|
67
|
+
- Firefox
|
|
68
|
+
- Safari
|
|
69
|
+
- Edge (once available)
|
|
70
|
+
|
|
71
|
+
When ready for review:
|
|
72
|
+
- [ ] add situationally appropriate reviewers
|
|
73
|
+
- [ ] added instructions for reviewers in your PR, letting them know what kind of review you need
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@hashicorp/design-system-components",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.6.0",
|
|
4
4
|
"description": "HashiCorp Design System Components",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"hashicorp",
|
|
@@ -34,7 +34,7 @@
|
|
|
34
34
|
"test:ember:percy": "percy exec ember test"
|
|
35
35
|
},
|
|
36
36
|
"dependencies": {
|
|
37
|
-
"@hashicorp/design-system-tokens": "^0.
|
|
37
|
+
"@hashicorp/design-system-tokens": "^0.8.0",
|
|
38
38
|
"@hashicorp/ember-flight-icons": "^2.0.1",
|
|
39
39
|
"ember-auto-import": "^2.2.3",
|
|
40
40
|
"ember-cli-babel": "^7.26.6",
|