fix: dashboard design feedback (#5104)

* fix: add createdby and createdAt by default and show not be configurable

* fix: make the checkbox always checked for createdby and createdat

* fix: decrease the margins for the graph and make it compact

* fix: decrease font size for metadata
This commit is contained in:
Vikrant Gupta 2024-05-29 18:58:02 +05:30 committed by GitHub
parent 1db1f76a72
commit 1328f05d78
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 14 additions and 16 deletions

View File

@ -143,7 +143,7 @@
slashed-zero; slashed-zero;
font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on; font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on;
font-family: Inter; font-family: Inter;
font-size: 14px; font-size: 12px;
font-style: normal; font-style: normal;
font-weight: 400; font-weight: 400;
line-height: 18px; /* 128.571% */ line-height: 18px; /* 128.571% */
@ -168,7 +168,7 @@
slashed-zero; slashed-zero;
font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on; font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on;
font-family: Inter; font-family: Inter;
font-size: 14px; font-size: 12px;
font-style: normal; font-style: normal;
font-weight: 400; font-weight: 400;
line-height: 18px; /* 128.571% */ line-height: 18px; /* 128.571% */
@ -192,7 +192,7 @@
slashed-zero; slashed-zero;
font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on; font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on;
font-family: Inter; font-family: Inter;
font-size: 14px; font-size: 12px;
font-style: normal; font-style: normal;
font-weight: 400; font-weight: 400;
line-height: 18px; /* 128.571% */ line-height: 18px; /* 128.571% */
@ -226,7 +226,7 @@
slashed-zero; slashed-zero;
font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on; font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on;
font-family: Inter; font-family: Inter;
font-size: 14px; font-size: 12px;
font-style: normal; font-style: normal;
font-weight: 400; font-weight: 400;
line-height: 18px; /* 128.571% */ line-height: 18px; /* 128.571% */

View File

@ -503,14 +503,12 @@ function DashboardsList(): JSX.Element {
</div> </div>
</div> </div>
<div className="dashboard-details"> <div className="dashboard-details">
{visibleColumns.createdAt && ( <div className="dashboard-created-at">
<div className="dashboard-created-at"> <CalendarClock size={14} />
<CalendarClock size={14} /> <Typography.Text>{formattedDateAndTime}</Typography.Text>
<Typography.Text>{formattedDateAndTime}</Typography.Text> </div>
</div>
)}
{dashboard.createdBy && visibleColumns.createdBy && ( {dashboard.createdBy && (
<div className="created-by"> <div className="created-by">
<div className="dashboard-tag"> <div className="dashboard-tag">
<Typography.Text className="tag-text"> <Typography.Text className="tag-text">
@ -900,7 +898,7 @@ function DashboardsList(): JSX.Element {
<div className="right"> <div className="right">
<Switch <Switch
size="small" size="small"
checked={visibleColumns.createdAt} checked
disabled disabled
onChange={(check): void => onChange={(check): void =>
setVisibleColumns((prev) => ({ setVisibleColumns((prev) => ({
@ -921,7 +919,7 @@ function DashboardsList(): JSX.Element {
<Switch <Switch
size="small" size="small"
disabled disabled
checked={visibleColumns.createdBy} checked
onChange={(check): void => onChange={(check): void =>
setVisibleColumns((prev) => ({ setVisibleColumns((prev) => ({
...prev, ...prev,

View File

@ -91,9 +91,9 @@ function WidgetGraph({
<div <div
ref={graphRef} ref={graphRef}
style={{ style={{
height: '80%', height: '100%',
width: '80%', width: '100%',
margin: 'auto auto', marginTop: '16px',
borderRadius: '3px', borderRadius: '3px',
border: isDarkMode border: isDarkMode
? '1px solid var(--bg-slate-500)' ? '1px solid var(--bg-slate-500)'