@cypress-design/react-tooltip 0.4.0 → 0.5.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.
@@ -0,0 +1,6 @@
1
+ $ yarn build:module && yarn build:types
2
+ $ rollup -c ./rollup.config.mjs
3
+ 
4
+ ./index.ts → ./dist/index.umd.js, ./dist/index.es.mjs...
5
+ created ./dist/index.umd.js, ./dist/index.es.mjs in 50.1s
6
+ $ tsc --project ./tsconfig.build.json
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @cypress-design/react-tooltip
2
2
 
3
+ ## 0.5.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#178](https://github.com/cypress-io/cypress-design/pull/178) [`d0de778`](https://github.com/cypress-io/cypress-design/commit/d0de77843adb87d8f4804219c6dca8f45b15c650) Thanks [@elevatebart](https://github.com/elevatebart)! - deliver new docs and improved components
8
+
9
+ ## 0.4.1
10
+
11
+ ### Patch Changes
12
+
13
+ - [#164](https://github.com/cypress-io/cypress-design/pull/164) [`4fd951a`](https://github.com/cypress-io/cypress-design/commit/4fd951a39335900da2508beef9b3565a6f8f9518) Thanks [@elevatebart](https://github.com/elevatebart)! - fix: update active buttons borders
14
+
3
15
  ## 0.4.0
4
16
 
5
17
  ### Minor Changes
package/ReadMe.md CHANGED
@@ -7,15 +7,15 @@ For accessibility, it also triggers on focus.
7
7
 
8
8
  To allow focus, one has to add `tabIndex="0"` to the Tooltip element.
9
9
 
10
- ```jsx
11
- const comp = () => (
12
- <Tooltip tabIndex="0">
10
+ ```jsx live
11
+ export const comp = () => (
12
+ <Tooltip tabIndex="0" popper={<b>popper</b>}>
13
13
  <span>Focus me</span>
14
14
  </Tooltip>
15
15
  )
16
16
  ```
17
17
 
18
- ## install
18
+ ## Install
19
19
 
20
20
  ```bash
21
21
  npm install @cypress-design/react-tooltip
@@ -13,10 +13,10 @@ export default ({
13
13
  disabled?: boolean
14
14
  tabIndex?: number
15
15
  } = {}) => (
16
- <div className="center flex flex-col items-center gap-20">
16
+ <div className="flex flex-col items-center center gap-20">
17
17
  <Tooltip
18
- className="bg-red-200 p-4 w-1/2"
19
- popper={<div className="bg-jade-200 text-gray-800 p-4">PopovDyn</div>}
18
+ className="w-1/2 p-4 bg-red-200"
19
+ popper={<div className="p-4 text-gray-800 bg-jade-200">PopovDyn</div>}
20
20
  color={color}
21
21
  placement={placement}
22
22
  tabIndex={tabIndex}
@@ -25,7 +25,7 @@ export default ({
25
25
  <div>Hover Me (dynamic: {placement?.toString()})</div>
26
26
  </Tooltip>
27
27
  <Tooltip
28
- className="bg-red-200 p-4 w-1/2"
28
+ className="w-1/2 p-4 bg-red-200"
29
29
  popper={
30
30
  <div className="h-[200px] flex items-center justify-center">Popov</div>
31
31
  }
@@ -36,7 +36,7 @@ export default ({
36
36
  <div>Force Placement to the top</div>
37
37
  </Tooltip>
38
38
  <Tooltip
39
- className="bg-red-200 p-4 w-1/2"
39
+ className="w-1/2 p-4 bg-red-200"
40
40
  popper={<div>PopovInt</div>}
41
41
  color={color}
42
42
  placement={placement}
@@ -47,14 +47,14 @@ export default ({
47
47
  {(['top', 'right', 'bottom', 'left', 'top-start'] as const).map(
48
48
  (placement) => (
49
49
  <Tooltip
50
- className="bg-indigo-200 p-4 w-1/2"
50
+ className="w-1/2 p-4 bg-indigo-200"
51
51
  placement={placement}
52
52
  key={placement}
53
53
  color={color}
54
54
  tabIndex={tabIndex}
55
55
  disabled={disabled}
56
56
  popper={
57
- <div className="bg-jade-200 text-gray-800 p-4">
57
+ <div className="p-4 text-gray-800 bg-jade-200">
58
58
  Popover ({placement})
59
59
  </div>
60
60
  }
@@ -1,7 +1,7 @@
1
1
  /// <reference types="cypress" />
2
2
 
3
3
  import * as React from 'react'
4
- import { mount } from 'cypress/react'
4
+ import { mount } from 'cypress/react18'
5
5
  import TooltipStory from './Tooltip.rootstory'
6
6
  import assertions from '../assertions'
7
7