Add beta tag to Hydraulic
This commit is contained in:
2 files changed
+4
-2
No files matched your search
@@ -11,10 +11,11 @@ export const Collapsibles = ({ children }) => {
|
|||||||
interface CollapsibleProps {
|
interface CollapsibleProps {
|
||||||
title: React.ReactNode;
|
title: React.ReactNode;
|
||||||
subtitle?: React.ReactNode;
|
subtitle?: React.ReactNode;
|
||||||
|
tags?: string[];
|
||||||
inner: React.ReactNode;
|
inner: React.ReactNode;
|
||||||
}
|
}
|
||||||
|
|
||||||
export const Collapsible: React.FC<CollapsibleProps> = ({ title, subtitle, inner }) => {
|
export const Collapsible: React.FC<CollapsibleProps> = ({ title, subtitle, inner, tags = [] }) => {
|
||||||
const [isInnerVisible, setIsInnerVisible] = useState(false);
|
const [isInnerVisible, setIsInnerVisible] = useState(false);
|
||||||
const innerRef = useRef(null);
|
const innerRef = useRef(null);
|
||||||
const [innerHeight, setInnerHeight] = useState(0);
|
const [innerHeight, setInnerHeight] = useState(0);
|
||||||
@@ -33,7 +34,7 @@ export const Collapsible: React.FC<CollapsibleProps> = ({ title, subtitle, inner
|
|||||||
<div className="collapsible">
|
<div className="collapsible">
|
||||||
<div className="collapsible-header" onClick={toggleVisibility}>
|
<div className="collapsible-header" onClick={toggleVisibility}>
|
||||||
<p>
|
<p>
|
||||||
<span className="collapsible-title">{title}</span>
|
<span className="collapsible-title">{title}{tags.map((tag) => (<span className='badge badge--primary' style={{marginLeft:"0.25rem"}}>{tag}</span>))}</span>
|
||||||
{subtitle && <span className="collapsible-subtitle"><br/>{subtitle}</span>}
|
{subtitle && <span className="collapsible-subtitle"><br/>{subtitle}</span>}
|
||||||
</p>
|
</p>
|
||||||
<span className={isInnerVisible ? 'collapsible-arrow expanded' : 'collapsible-arrow'}></span>
|
<span className={isInnerVisible ? 'collapsible-arrow expanded' : 'collapsible-arrow'}></span>
|
||||||
|
|||||||
@@ -102,6 +102,7 @@ const DownloadPage: React.FC = () => (
|
|||||||
<Collapsible
|
<Collapsible
|
||||||
title='Hydraulic'
|
title='Hydraulic'
|
||||||
subtitle={<Translate id='pages.download.description.hydraulic'>A companion mod to Geyser which allows for Bedrock players to join modded Minecraft: Java Edition servers.</Translate>}
|
subtitle={<Translate id='pages.download.description.hydraulic'>A companion mod to Geyser which allows for Bedrock players to join modded Minecraft: Java Edition servers.</Translate>}
|
||||||
|
tags={['Beta']}
|
||||||
inner={
|
inner={
|
||||||
<ProjectDownload
|
<ProjectDownload
|
||||||
projectId="hydraulic"
|
projectId="hydraulic"
|
||||||
|
|||||||
Reference in new issue
Block a user