@@ -5,6 +5,7 @@ import { TooltipProvider, TooltipWrapper } from 'components/TooltipProvider'
5
5
import { IPosition } from 'components/Tooltip/TooltipTypes.d'
6
6
import { useState } from 'react'
7
7
import styles from './styles.module.css'
8
+ import { inline , offset } from './index'
8
9
9
10
function WithProviderMinimal ( ) {
10
11
return (
@@ -202,6 +203,65 @@ function App() {
202
203
content = "Showing tooltip and calling afterShow method"
203
204
/>
204
205
</ div >
206
+
207
+ < div
208
+ style = { {
209
+ width : 700 ,
210
+ position : 'relative' ,
211
+ overflow : 'hidden' ,
212
+ marginTop : '1rem' ,
213
+
214
+ boxSizing : 'border-box' ,
215
+ } }
216
+ >
217
+ < p >
218
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt
219
+ < span id = "withoutCustomMiddleware" style = { { color : 'blue' , fontWeight : 'bold' } } >
220
+ labore et dolore magna aliqua
221
+ </ span >
222
+ . Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
223
+ commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum
224
+ dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in
225
+ culpa qui officia deserunt mollit anim id est laborum.
226
+ </ p >
227
+
228
+ < Tooltip
229
+ place = "top"
230
+ anchorId = "withoutCustomMiddleware"
231
+ content = "Showing tooltip with default middlewares"
232
+ positionStrategy = "fixed"
233
+ />
234
+ </ div >
235
+
236
+ < div
237
+ style = { {
238
+ width : 700 ,
239
+ position : 'relative' ,
240
+ overflow : 'hidden' ,
241
+ marginTop : '1rem' ,
242
+
243
+ boxSizing : 'border-box' ,
244
+ } }
245
+ >
246
+ < p >
247
+ Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt
248
+ < span id = "withCustomMiddleware" style = { { color : 'blue' , fontWeight : 'bold' } } >
249
+ labore et dolore magna aliqua
250
+ </ span >
251
+ . Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea
252
+ commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum
253
+ dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in
254
+ culpa qui officia deserunt mollit anim id est laborum.
255
+ </ p >
256
+
257
+ < Tooltip
258
+ place = "top"
259
+ anchorId = "withCustomMiddleware"
260
+ content = "Showing tooltip with custom inline middleware"
261
+ positionStrategy = "fixed"
262
+ middlewares = { [ inline ( ) , offset ( 10 ) ] }
263
+ />
264
+ </ div >
205
265
</ main >
206
266
)
207
267
}
0 commit comments