aboutsummaryrefslogtreecommitdiff
path: root/FrontEnd/src/app/views/timeline
diff options
context:
space:
mode:
authorcrupest <crupest@outlook.com>2020-11-04 12:29:55 +0800
committerGitHub <noreply@github.com>2020-11-04 12:29:55 +0800
commit1e9e5eb89099ffaa454635fdd7271cece757fb2d (patch)
tree1f19646ac27a3dcd4680e871f34218b85b0915d8 /FrontEnd/src/app/views/timeline
parentf3503b399ff7b65f363beca313c8a0c336884bec (diff)
parent1ba32f233677cad56636462b1f6552ff6e800801 (diff)
downloadtimeline-1e9e5eb89099ffaa454635fdd7271cece757fb2d.tar.gz
timeline-1e9e5eb89099ffaa454635fdd7271cece757fb2d.tar.bz2
timeline-1e9e5eb89099ffaa454635fdd7271cece757fb2d.zip
Merge pull request #165 from crupest/timeline
Redesign timeline ui.
Diffstat (limited to 'FrontEnd/src/app/views/timeline')
-rw-r--r--FrontEnd/src/app/views/timeline/TimelineDeleteDialog.tsx14
-rw-r--r--FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx2
2 files changed, 8 insertions, 8 deletions
diff --git a/FrontEnd/src/app/views/timeline/TimelineDeleteDialog.tsx b/FrontEnd/src/app/views/timeline/TimelineDeleteDialog.tsx
index 894b8195..33609158 100644
--- a/FrontEnd/src/app/views/timeline/TimelineDeleteDialog.tsx
+++ b/FrontEnd/src/app/views/timeline/TimelineDeleteDialog.tsx
@@ -33,15 +33,15 @@ const TimelineDeleteDialog: React.FC<TimelineDeleteDialog> = (props) => {
inputScheme={[
{
type: "text",
- validator: (value) => {
- if (value !== name) {
- return "timeline.deleteDialog.notMatch";
- } else {
- return null;
- }
- },
},
]}
+ inputValidator={([value]) => {
+ if (value !== name) {
+ return { 0: "timeline.deleteDialog.notMatch" };
+ } else {
+ return null;
+ }
+ }}
onProcess={() => {
return timelineService.deleteTimeline(name).toPromise();
}}
diff --git a/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx b/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
index abc3d0c9..1070c6d7 100644
--- a/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
+++ b/FrontEnd/src/app/views/timeline/TimelineInfoCard.tsx
@@ -36,7 +36,7 @@ const TimelineInfoCard: React.FC<TimelineInfoCardProps> = (props) => {
collapse={collapse}
toggleCollapse={toggleCollapse}
>
- <h3 className="text-primary mx-3 d-inline-block align-middle">
+ <h3 className="text-primary d-inline-block align-middle">
{timeline.title}
<small className="ml-3 text-secondary">{timeline.name}</small>
</h3>