File tree Expand file tree Collapse file tree 2 files changed +10
-9
lines changed
src/spaces/mcp/components Expand file tree Collapse file tree 2 files changed +10
-9
lines changed Original file line number Diff line number Diff line change @@ -22,9 +22,9 @@ describe('McpHeader', () => {
2222
2323 cy . mount ( < McpHeader mcp = { mcp } /> ) ;
2424
25- cy . contains ( 'span' , ' my-control-plane') . should ( 'be.visible' ) ;
26- cy . contains ( 'span' , ' alice@example.com') . should ( 'be.visible' ) ;
27- cy . contains ( 'span' , `${ creationDateAsString } (2 days ago)` ) . should ( 'be.visible' ) ;
25+ cy . contains ( 'my-control-plane' ) . should ( 'be.visible' ) ;
26+ cy . contains ( 'alice@example.com' ) . should ( 'be.visible' ) ;
27+ cy . contains ( `${ creationDateAsString } (2 days ago)` ) . should ( 'be.visible' ) ;
2828 } ) ;
2929
3030 it ( 'renders with missing MCP metadata' , ( ) => {
@@ -44,7 +44,7 @@ describe('McpHeader', () => {
4444
4545 cy . mount ( < McpHeader mcp = { mcp } /> ) ;
4646
47- cy . contains ( 'span' , ' my-control-plane') . should ( 'be.visible' ) ;
48- cy . contains ( 'span' , `${ creationDateAsString } (2 days ago)` ) . should ( 'be.visible' ) ;
47+ cy . contains ( 'my-control-plane' ) . should ( 'be.visible' ) ;
48+ cy . contains ( `${ creationDateAsString } (2 days ago)` ) . should ( 'be.visible' ) ;
4949 } ) ;
5050} ) ;
Original file line number Diff line number Diff line change 11import { ControlPlaneType } from '../../../lib/api/types/crate/controlPlanes.ts' ;
2+ import { Text } from '@ui5/webcomponents-react' ;
23
34import styles from './McpHeader.module.css' ;
45import { formatDateAsTimeAgo } from '../../../utils/i18n/timeAgo.ts' ;
@@ -23,17 +24,17 @@ export function McpHeader({ mcp }: McpHeaderProps) {
2324 < div className = { styles . container } >
2425 < div className = { styles . grid } >
2526 < span className = { styles . label } > { t ( 'McpHeader.nameLabel' ) } </ span >
26- < span > { mcp . metadata . name } </ span >
27+ < Text > { mcp . metadata . name } </ Text >
2728
2829 < span className = { styles . label } > { t ( 'McpHeader.createdOnLabel' ) } </ span >
29- < span >
30+ < Text >
3031 { created } ({ formatDateAsTimeAgo ( mcp . metadata . creationTimestamp ) } )
31- </ span >
32+ </ Text >
3233
3334 { createdBy ? (
3435 < >
3536 < span className = { styles . label } > { t ( 'McpHeader.createdByLabel' ) } </ span >
36- < span > { createdBy } </ span >
37+ < Text > { createdBy } </ Text >
3738 </ >
3839 ) : null }
3940 </ div >
You can’t perform that action at this time.
0 commit comments