@equinor/eds-core-react 1.0.2 → 2.0.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.
Files changed (57) hide show
  1. package/README.md +16 -1
  2. package/dist/eds-core-react.cjs +421 -136
  3. package/dist/esm/components/Accordion/Accordion.js +4 -3
  4. package/dist/esm/components/Autocomplete/Autocomplete.js +90 -23
  5. package/dist/esm/components/Autocomplete/Autocomplete.tokens.js +1 -1
  6. package/dist/esm/components/Button/tokens/contained.js +1 -1
  7. package/dist/esm/components/Button/tokens/contained_icon.js +1 -1
  8. package/dist/esm/components/Button/tokens/ghost.js +1 -1
  9. package/dist/esm/components/Button/tokens/icon.js +1 -1
  10. package/dist/esm/components/Button/tokens/outlined.js +1 -1
  11. package/dist/esm/components/Datepicker/fields/FieldWrapper.js +8 -2
  12. package/dist/esm/components/Icon/Icon.js +2 -3
  13. package/dist/esm/components/Input/Input.tokens.js +1 -1
  14. package/dist/esm/components/InputWrapper/InputWrapper.tokens.js +1 -1
  15. package/dist/esm/components/InputWrapper/useInputField.js +61 -0
  16. package/dist/esm/components/SideBar/SideBarAccordion/index.js +4 -3
  17. package/dist/esm/components/Slider/Slider.js +8 -5
  18. package/dist/esm/components/Table/DataCell/DataCell.tokens.js +1 -1
  19. package/dist/esm/components/Tabs/Tabs.js +4 -3
  20. package/dist/esm/components/TextField/TextField.js +23 -56
  21. package/dist/esm/components/Textarea/Textarea.js +64 -33
  22. package/dist/esm/components/Typography/Heading.js +51 -0
  23. package/dist/esm/components/Typography/Paragraph.js +28 -0
  24. package/dist/esm/components/Typography/Typography.js +15 -1
  25. package/dist/esm/components/Typography/Typography.new.js +67 -0
  26. package/dist/esm/index.js +5 -0
  27. package/dist/types/components/Button/tokens/contained.d.ts +3 -4
  28. package/dist/types/components/Button/tokens/outlined.d.ts +3 -4
  29. package/dist/types/components/InputWrapper/index.d.ts +3 -0
  30. package/dist/types/components/InputWrapper/types.d.ts +21 -0
  31. package/dist/types/components/InputWrapper/useInputField.d.ts +31 -0
  32. package/dist/types/components/TextField/TextField.d.ts +5 -25
  33. package/dist/types/components/Textarea/Textarea.d.ts +6 -27
  34. package/dist/types/components/Typography/Heading.d.ts +7 -0
  35. package/dist/types/components/Typography/Heading.types.d.ts +6 -0
  36. package/dist/types/components/Typography/Paragraph.d.ts +7 -0
  37. package/dist/types/components/Typography/Paragraph.types.d.ts +7 -0
  38. package/dist/types/components/Typography/Typography.d.ts +13 -0
  39. package/dist/types/components/Typography/Typography.new.d.ts +43 -0
  40. package/dist/types/components/Typography/Typography.new.types.d.ts +28 -0
  41. package/dist/types/components/Typography/Typography.stories.shared.d.ts +79 -0
  42. package/dist/types/components/Typography/index.d.ts +7 -0
  43. package/dist/types/components/Typography/types.d.ts +9 -0
  44. package/dist/types/components/Typography/utils.d.ts +15 -0
  45. package/dist/types/index.d.ts +1 -0
  46. package/package.json +56 -40
  47. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_curry1.js +0 -0
  48. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_curry2.js +0 -0
  49. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_curry3.js +0 -0
  50. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_has.js +0 -0
  51. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_isObject.js +0 -0
  52. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/internal/_isPlaceholder.js +0 -0
  53. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/mergeDeepRight.js +0 -0
  54. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/mergeDeepWithKey.js +0 -0
  55. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/mergeWith.js +0 -0
  56. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/mergeWithKey.js +0 -0
  57. /package/dist/esm/node_modules/.pnpm/{ramda@0.31.3 → ramda@0.32.0}/node_modules/ramda/es/pickBy.js +0 -0
package/README.md CHANGED
@@ -8,7 +8,7 @@ Read the [changelog](https://github.com/equinor/design-system/blob/main/packages
8
8
  ## Installation
9
9
 
10
10
  ```sh
11
- npm install @equinor/eds-core-react styled-components
11
+ npm install @equinor/eds-core-react @equinor/eds-tokens styled-components
12
12
  ```
13
13
  If you use Typescript, make sure you have typescript >= 3.8 as a devDependency:
14
14
  ```sh
@@ -23,6 +23,21 @@ npm install typescript --save-dev
23
23
  <link rel="stylesheet" href="https://cdn.eds.equinor.com/font/equinor-font.css" />
24
24
  ```
25
25
 
26
+ ### Required Stylesheets
27
+
28
+ EDS Core React components require css variables and foundation styles for typography and spacing. Import both stylesheets from `@equinor/eds-tokens`:
29
+
30
+ ```css
31
+ @import '@equinor/eds-tokens/css/variables';
32
+ @import '@equinor/eds-tokens/css/foundation';
33
+ ```
34
+
35
+ **Why both?**
36
+ - **Variables CSS** (`/css/variables`) provides all design tokens (colors, spacing, typography variables)
37
+ - **Foundation CSS** (`/css/foundation`) provides typography and spacing utility classes used in our components.
38
+
39
+ For more information about the typography system, see the [Typography component documentation](./src/components/Typography/README.md).
40
+
26
41
  ## Usage
27
42
 
28
43
  ```jsx