Skip to content

Commit

Permalink
Improve the styles.
Browse files Browse the repository at this point in the history
  • Loading branch information
yjcyxky committed Mar 29, 2024
1 parent 5cf3163 commit 61a3c63
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 11 deletions.
4 changes: 2 additions & 2 deletions studio/src/EdgeInfoPanel/PublicationDesc.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React, { useState } from 'react';
import { Button } from 'antd';
import { Button, Tag } from 'antd';
import parse from 'html-react-parser';
import type { PublicationDetail } from 'biominer-components/dist/typings';

Expand Down Expand Up @@ -61,7 +61,7 @@ const Desc: React.FC<{
<p>{parse(highlightWords(abstract, props.queryStr.split(SEPARATOR)))}</p> : null
}
<p>
{publication.year} | {publication.journal} &nbsp; | &nbsp; {publication.authors ? publication.authors.join(', ') : 'Unknown'}
<Tag>{publication.year}</Tag><Tag>Journal&nbsp;|&nbsp;{publication.journal}</Tag>&nbsp;{publication.authors ? publication.authors.join(', ') : 'Unknown'}
</p>
{
<p>
Expand Down
3 changes: 1 addition & 2 deletions studio/src/EdgeInfoPanel/PublicationPanel.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -93,9 +93,8 @@ const PublicationPanel: React.FC<PublicationPanelProps> = (props) => {
<>
<div className='publication-panel-header'>
<h3>
Relevant Publications
Top 10 Relevant Publications [<span>Keywords: {props.queryStr.split('#').join(', ')}</span>]
</h3>
<span>Keywords: {props.queryStr.split('#').join(', ')}</span>
</div>
<List
loading={loading}
Expand Down
8 changes: 7 additions & 1 deletion studio/src/EdgeInfoPanel/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@

.publication-panel-header {
position: absolute;
top: 10px;
top: 5px;
left: 22px;
z-index: 100;

Expand All @@ -29,6 +29,12 @@
}
}

.ant-list {
.ant-list-pagination {
margin-block-start: 0;
}
}

.highlight {
color: #1890ff;
}
Expand Down
2 changes: 1 addition & 1 deletion studio/src/global.less
Original file line number Diff line number Diff line change
Expand Up @@ -132,7 +132,7 @@ ol {
// }
// }

&::-webkit-scrollbar {
::-webkit-scrollbar {
display: none;
}

Expand Down
12 changes: 7 additions & 5 deletions studio/src/pages/Home/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -255,11 +255,13 @@ const HomePage: React.FC = () => {
<Row className="welcome">
<Row className="box">
<Col className="header">
<h4 style={{ textAlign: 'center' }}>Enter a gene/protein, disease, drug or symptom name to find and explain related known knowledges in our platform.<br /> If you want to predict new knowledges, please go to the <a onClick={
() => {
history.push('/predict-model');
}
}>Predict Drug/Target</a> page.</h4>
<h4 style={{ textAlign: 'center', fontSize: '16px', lineHeight: '24px' }}>
Enter a gene/protein, disease, drug or symptom name to find and explain related known knowledges in our platform.
<br />
If you want to predict new knowledges, please go to the <a onClick={() => { history.push('/predict-model'); }}>Predict Drug/Target</a> page.
<br />
Please click the following examples to see the results.
</h4>
<Select
showSearch
allowClear
Expand Down
4 changes: 4 additions & 0 deletions studio/src/pages/KnowledgeTable/index.less
Original file line number Diff line number Diff line change
Expand Up @@ -59,3 +59,7 @@
max-width: 450px;
white-space: wrap;
}

.popover-note {
width: 300px;
}
1 change: 1 addition & 0 deletions studio/src/pages/KnowledgeTable/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -448,6 +448,7 @@ const KnowledgeTable: React.FC = (props) => {
</>
}
title="Note"
overlayClassName='popover-note'
>
<Button type="primary" onClick={() => {
setEdgeInfo({
Expand Down

0 comments on commit 61a3c63

Please sign in to comment.