Skip to content

Commit

Permalink
Update the DatasetDetails to show the tags, Update InferenceServerInf…
Browse files Browse the repository at this point in the history
…o to show the inferenc_server_possibel, Add the InferenceServerInfo.module.sccs
  • Loading branch information
Rahil Ashtari Mahini committed Jul 29, 2024
1 parent 1a38cba commit 4e9378c
Show file tree
Hide file tree
Showing 3 changed files with 69 additions and 4 deletions.
4 changes: 2 additions & 2 deletions src/app/MlHub/Datasets/DatasetDetails.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const DatasetDetails: React.FC<DatasetDetailsProps> = ({ datasetId }) => {
</div>
)}

{dataset.last_modified && (
{dataset.created_at && (
<div className={`${styles['dataset-detail']}`}>
<div className={`${styles['dataset-title']}`}>created_at:</div>
<div className={`${styles['detail-info']}`}>
Expand All @@ -64,7 +64,7 @@ const DatasetDetails: React.FC<DatasetDetailsProps> = ({ datasetId }) => {

{dataset.tags && (
<div className={`${styles['dataset-detail']}`}>
<div className={`${styles['dataset-title']}`}>last_modified:</div>
<div className={`${styles['dataset-title']}`}>tags:</div>
<div className={`${styles['detail-info']}`}>{dataset.tags}</div>
</div>
)}
Expand Down
63 changes: 63 additions & 0 deletions src/app/MlHub/Models/InferenceServerInfo.module.scss
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
.model-details {
padding-left: 1em;
padding-right: 1em;
}

.buttons-container {
display: flex;
flex-direction: column;
position: absolute;
top: 0px;
right: 0px;
gap: 20px;
}

.model-details-wrapper {
display: flex;
flex-direction: row;
width: 100%;
position: relative;
}

.model-details {
display: flex;
flex-direction: column;
gap: 16px;
flex: 1;
}

.model-title {
padding-bottom: 8px;
margin-left: 10px;
}

.model-detail {
display: flex;
flex-direction: row;
}

.detail-title {
font-weight: bold;
width: 15vw;
}

.detail-info {
margin-left: 8px;
text-align: left;
}

.model-title-container {
border-bottom: 1px solid black;
margin-bottom: 8px;
}

.download-links {
flex-grow: 1;
display: flex;
flex-direction: column;
padding-bottom: 5px;
}

.download-url-button {
height: 40px;
}
6 changes: 4 additions & 2 deletions src/app/MlHub/Models/InferenceServerInfo.tsx
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
import React from 'react';
import { MLHub as Hooks } from '@tapis/tapisui-hooks';
import { JSONDisplay } from '@tapis/tapisui-common';
import styles from './ModelDetails.module.scss';
import { QueryWrapper } from '@tapis/tapisui-common';
import { Link, useRouteMatch } from 'react-router-dom';
import styles from './InferenceServerInfo.module.scss';

type InferenceServerInfoProps = {
modelId: string;
Expand Down Expand Up @@ -87,7 +87,9 @@ const InferenceServerInfo: React.FC<InferenceServerInfoProps> = ({
inference_server_possible:
</div>
<div className={`${styles['detail-info']}`}>
{String(serverInfo.result?.inference_server_possible)}
{!!serverInfo.result?.inference_server_possible === false
? 'false'
: 'true'}
</div>
</div>
</>
Expand Down

0 comments on commit 4e9378c

Please sign in to comment.