Skip to content

Commit

Permalink
beautify
Browse files Browse the repository at this point in the history
  • Loading branch information
Kei18 committed Dec 27, 2023
1 parent 4622787 commit c95a430
Show file tree
Hide file tree
Showing 2 changed files with 85 additions and 82 deletions.
4 changes: 1 addition & 3 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
[project-page-generator](https://github.com/Kei18/project-page-generator)
===
# [project-page-generator](https://github.com/Kei18/project-page-generator)

Simple project-page generator for research, assuming hosted on GitHub Pages.

Expand Down Expand Up @@ -37,7 +36,6 @@ yarn serve

You can see the website via `http://localhost:1234`.


### 4. Push

```sh
Expand Down
163 changes: 84 additions & 79 deletions src/ts/app.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -57,33 +57,35 @@ const App: React.SFC<{}> = () => {
if (item.url) {
return (
<div key={i} className="col-sm">
<a href={item.url} className="h5">{item.name}</a>
{item.affiliation
? (
<small>
<br />
<span className="text-secondary">
{item.affiliation}
</span>
</small>
) : ""
}
<a href={item.url} className="h5">
{item.name}
</a>
{item.affiliation ? (
<small>
<br />
<span className="text-secondary">
{item.affiliation}
</span>
</small>
) : (
""
)}
</div>
);
} else {
return (
<div key={i} className="col-sm">
<span className="h5">{item.name}</span>
{item.affiliation
? (
<small>
<br />
<span className="text-secondary">
{item.affiliation}
</span>
</small>
) : ""
}
{item.affiliation ? (
<small>
<br />
<span className="text-secondary">
{item.affiliation}
</span>
</small>
) : (
""
)}
</div>
);
}
Expand Down Expand Up @@ -117,14 +119,14 @@ const App: React.SFC<{}> = () => {
) : (
""
)}
{data.headerDescription ? (
<div
className="text-secondary text-center"
dangerouslySetInnerHTML={{ __html: data.headerDescription }}
></div>
) : (
""
)}
{data.headerDescription ? (
<div
className="text-secondary text-center"
dangerouslySetInnerHTML={{ __html: data.headerDescription }}
></div>
) : (
""
)}
</div>
) : (
""
Expand Down Expand Up @@ -178,7 +180,7 @@ const App: React.SFC<{}> = () => {
""
)}

{data.demo ? (
{data.demo ? (
<div className="mx-auto mt-5">
<p className="h5">Demo</p>
<div className="row">
Expand All @@ -204,37 +206,42 @@ const App: React.SFC<{}> = () => {
""
)}
{item.description ? <p>{item.description}</p> : ""}
</div>
</div>
);
})}
</div>
</div>
) : (
""
)}
</div>
</div>
) : (
""
)}

{data.performance ? (
<div className="mx-auto mt-5">
{data.performance ? (
<div className="mx-auto mt-5">
<p className="h5">Performance</p>
{images_png[data.performance.image] ? (
<img src={images_png[data.performance.image]} className="img-fluid" />
<img
src={images_png[data.performance.image]}
className="img-fluid"
/>
) : (
""
""
)}
{data.headerDescription ? (
<small>
<div
className="mt-3 text-secondary"
dangerouslySetInnerHTML={{ __html: data.performance.description }}
></div></small>
{data.headerDescription ? (
<small>
<div
className="mt-3 text-secondary"
dangerouslySetInnerHTML={{
__html: data.performance.description,
}}
></div>
</small>
) : (
""
)}
</div>
) : (
""
""
)}
</div>
) : (
""
)}


{data.video ? (
<div className="mx-auto mt-5">
Expand All @@ -257,23 +264,21 @@ const App: React.SFC<{}> = () => {
{data.slides ? (
<div className="mx-auto mt-5">
<p className="h5">Slides</p>
<div>
{
data.slides.map((item, i) => (
<div key={i} className="mb-5">
<p>{item.title}</p>
<div className="slide-wrapper">
<iframe
src={item.url}
allowFullScreen
scrolling="no"
allow="encrypted-media;"
></iframe>
</div>
</div>
))
}
<div>
{data.slides.map((item, i) => (
<div key={i} className="mb-5">
<p>{item.title}</p>
<div className="slide-wrapper">
<iframe
src={item.url}
allowFullScreen
scrolling="no"
allow="encrypted-media;"
></iframe>
</div>
</div>
))}
</div>
</div>
) : (
""
Expand All @@ -292,20 +297,20 @@ const App: React.SFC<{}> = () => {
""
)}

{data.otherLinks ? (
<div className="mx-auto mt-5">
{data.otherLinks ? (
<div className="mx-auto mt-5">
<p className="h5">Other Links</p>
<ul>
{data.otherLinks.map((item, i) => (
{data.otherLinks.map((item, i) => (
<li key={i}>
<a href={item.url}>{item.name}</a>
</li>
))}
</ul>
</div>
) : (
""
)}
<a href={item.url}>{item.name}</a>
</li>
))}
</ul>
</div>
) : (
""
)}

{data.contact ? (
<div className="mx-auto mt-5">
Expand Down

0 comments on commit c95a430

Please sign in to comment.