-
Notifications
You must be signed in to change notification settings - Fork 14
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(admin-ui): added custom tooltip
- Loading branch information
1 parent
d283b04
commit 07eb695
Showing
2 changed files
with
26 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
import React from 'react' | ||
|
||
function TooltipDesign({ payload }) { | ||
let objValues = { | ||
client_credentials_access_token_count: | ||
'Client credentials access token count', | ||
authz_code_access_token_count: 'Authz code access token count', | ||
authz_code_idtoken_count: 'Authz code idtoken count', | ||
} | ||
return ( | ||
<div className="bg-white thumbnail p-2"> | ||
{payload.length && | ||
payload.map((item, key) => { | ||
return ( | ||
<div key={key} style={{ fontSize: '12px' }}> | ||
{objValues[item.dataKey]} : {item.payload[item.dataKey]} | ||
</div> | ||
) | ||
})} | ||
</div> | ||
) | ||
} | ||
|
||
export default TooltipDesign |