Skip to content

Commit

Permalink
Merge branch 'develop' into main-to-dev
Browse files Browse the repository at this point in the history
  • Loading branch information
jhqwqmc committed Aug 11, 2024
2 parents fb3d747 + d5c03e2 commit 8e71629
Show file tree
Hide file tree
Showing 13 changed files with 109 additions and 6 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/build-development-jars-and-publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ jobs:
paper
purpur
game-versions: |
[1.20.3, 1.20.6]
[1.21]
dependencies: |
packetevents
Expand Down
5 changes: 5 additions & 0 deletions documentation/blog/authors.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,8 @@ gabber235:
title: TypeWriter Maintainer
url: https://github.com/gabber235
image_url: https://github.com/gabber235.png
MartenMrfc:
name: MartenMrfc
title: Documentation Maintainer
url: https://github.com/marten-mrfc
image_url: https://github.com/marten-mrfc.png
Original file line number Diff line number Diff line change
Expand Up @@ -120,4 +120,4 @@ You must recalculate the edges using the redstone from your hotbar after adding
When you have a lot of nodes, it can be hard to see which nodes are connected to each other. To make this easier, you can highlight the nodes that are connected to each other. To do this, select the glowstone from your hotbar and right-click it.

## Ending
Now you have learned how to successfully what the road network is and how to set it up.
Now you have learned how to successfully set up the road network.
7 changes: 7 additions & 0 deletions documentation/docusaurus.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@ const config = {
},
blog: {
showReadingTime: true,
onUntruncatedBlogPosts: 'ignore',
editUrl:
'https://github.com/gabber235/TypeWriter/tree/develop/documentation/',
},
Expand All @@ -72,6 +73,12 @@ const config = {
themeConfig:
/** @type {import('@docusaurus/preset-classic').ThemeConfig} */
({
announcementBar: {
id: 'support_us',
content:
'TypeWriter 0.5.0 is out!',
isCloseable: true,
},
mermaid: {
theme: { light: 'base', dark: 'base' },
options: {
Expand Down
24 changes: 24 additions & 0 deletions documentation/src/theme/AnnouncementBar/CloseButton/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
import React from 'react';
import clsx from 'clsx';
import {translate} from '@docusaurus/Translate';
import IconClose from '@theme/Icon/Close';
import type {Props} from '@theme/AnnouncementBar/CloseButton';
import styles from './styles.module.css';

export default function AnnouncementBarCloseButton(
props: Props,
): JSX.Element | null {
return (
<button
type="button"
aria-label={translate({
id: 'theme.AnnouncementBar.closeButtonAriaLabel',
message: 'Close',
description: 'The ARIA label for close button of announcement bar',
})}
{...props}
className={clsx('clean-btn close text-white opacity-100 hover:scale-110 transition-transform duration-200 ease-in-out hover:opacity-90', props.className)}>
<IconClose width={14} height={14} strokeWidth={3.1} />
</button>
);
}
Empty file.
19 changes: 19 additions & 0 deletions documentation/src/theme/AnnouncementBar/Content/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
import React from 'react';
import clsx from 'clsx';
import {useThemeConfig} from '@docusaurus/theme-common';
import type {Props} from '@theme/AnnouncementBar/Content';

export default function AnnouncementBarContent(
props: Props,
): JSX.Element | null {
const {announcementBar} = useThemeConfig();
const {content} = announcementBar!;

return (
<div
{...props}
className={clsx('flex items-center justify-center text-center text-xl font-bold', props.className)}
dangerouslySetInnerHTML={{__html: content}}
/>
);
}
15 changes: 15 additions & 0 deletions documentation/src/theme/AnnouncementBar/Content/styles.module.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
.content {
font-size: 85%;
text-align: center;
padding: 5px 0;
}

.content a {
color: var(--ifm-color-primary);
text-decoration: underline;
}

.content a:hover {
color: var(--ifm-color-primary-dark);
text-decoration: none;
}
33 changes: 33 additions & 0 deletions documentation/src/theme/AnnouncementBar/index.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
import React from 'react';
import {useThemeConfig} from '@docusaurus/theme-common';
import {useAnnouncementBar} from '@docusaurus/theme-common/internal';
import AnnouncementBarCloseButton from '@theme/AnnouncementBar/CloseButton';
import AnnouncementBarContent from '@theme/AnnouncementBar/Content';

export default function AnnouncementBar(): JSX.Element | null {
const {announcementBar} = useThemeConfig();
const {isActive, close} = useAnnouncementBar();

if (!isActive) {
return null;
}

const {isCloseable} = announcementBar!;

return (
<div
className={`flex items-center justify-between p-0 bg-[#227c9d] text-white shadow-lg transition-all duration-300 ease-in-out ${
isCloseable ? 'relative' : 'border-b'
}`}
role="banner">
{isCloseable && <div className="flex-none w-12" />}
<AnnouncementBarContent className="flex-1 text-center text-2xl" />
{isCloseable && (
<AnnouncementBarCloseButton
onClick={close}
className="flex-none mr-2 w-12 h-full cursor-pointer"
/>
)}
</div>
);
}
Original file line number Diff line number Diff line change
Expand Up @@ -120,4 +120,4 @@ You must recalculate the edges using the redstone from your hotbar after adding
When you have a lot of nodes, it can be hard to see which nodes are connected to each other. To make this easier, you can highlight the nodes that are connected to each other. To do this, select the glowstone from your hotbar and right-click it.

## Ending
Now you have learned how to successfully what the road network is and how to set it up.
Now you have learned how to successfully set up the road network.
2 changes: 1 addition & 1 deletion plugin/build.gradle.kts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ dependencies {
for (dependency in centralDependencies) {
compileOnlyApi(dependency)
}
compileOnlyApi("io.papermc.paper:paper-api:1.20.6-R0.1-SNAPSHOT")
compileOnlyApi("io.papermc.paper:paper-api:1.21-R0.1-SNAPSHOT")

api("com.github.Tofaa2.EntityLib:spigot:2.4.9-SNAPSHOT")
api("com.github.shynixn.mccoroutine:mccoroutine-bukkit-api:2.17.0")
Expand Down
2 changes: 1 addition & 1 deletion plugin/src/main/resources/plugin.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name: Typewriter
version: '${version}'
main: me.gabber235.typewriter.Typewriter
api-version: "1.20"
api-version: "1.21"
softdepend:
- PlaceholderAPI
- floodgate
Expand Down
2 changes: 1 addition & 1 deletion version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.5.1
0.6.0

0 comments on commit 8e71629

Please sign in to comment.