forked from Mirror/ollama4j
Updated docs
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
import React, { useState, useEffect } from 'react';
|
||||
|
||||
const LatestRelease = () => {
|
||||
const LatestRelease = ({ showReleaseDate }) => {
|
||||
const [releaseInfo, setReleaseInfo] = useState(null);
|
||||
const [loading, setLoading] = useState(true);
|
||||
const [error, setError] = useState(null);
|
||||
@@ -37,7 +37,8 @@ const LatestRelease = () => {
|
||||
<div>
|
||||
{/* <h4 style={{ display: 'flex', justifyContent: 'center'}}>Latest Release</h4> */}
|
||||
<div>
|
||||
<span style={{ fontWeight: 'bold'}}>Latest Version</span>: <a href={releaseInfo.html_url} target='_blank' rel="noopener noreferrer"><span style={{color: 'white', fontWeight: 'bold', backgroundColor:'#11bc11', borderRadius: '15px', padding: '5px'}}>{releaseInfo.name}</span></a> released on {new Date(releaseInfo.published_at).toLocaleDateString(undefined, { year: 'numeric', month: 'long', day: 'numeric' })}.
|
||||
<span style={{ fontWeight: 'bold'}}>Latest Version</span>: <a href={releaseInfo.html_url} target='_blank' rel="noopener noreferrer"><span style={{color: 'white', fontWeight: 'bold', backgroundColor:'#11bc11', borderRadius: '15px', padding: '5px'}}>{releaseInfo.name}</span></a>
|
||||
{showReleaseDate && ` released on ${new Date(releaseInfo.published_at).toLocaleDateString(undefined, { year: 'numeric', month: 'long', day: 'numeric' })}`}
|
||||
</div>
|
||||
{/* <pre style={{ whiteSpace: 'pre-wrap' }}>
|
||||
{JSON.stringify(releaseInfo, null, 2)}
|
||||
|
||||
Reference in New Issue
Block a user