Refactor components and pages for improved readability and consistency
- Updated BackgroundImage.astro to format props for better readability. - Adjusted FightTable.svelte to remove unnecessary trailing commas. - Modified GroupTable.svelte to fix sorting syntax. - Cleaned up LanguageWarning.astro by standardizing import statements. - Enhanced Login.svelte for better formatting and readability. - Simplified Navbar.svelte by merging multi-line attributes into single lines. - Streamlined PostComponent.astro by condensing Image component props. - Improved SearchComponent.svelte for consistent spacing and formatting. - Refined TagComponent.astro for better readability and structure. - Updated PageLayout.astro to simplify div structure. - Enhanced downloads.astro for improved readability and consistency. - Cleaned up index.astro in help directory for better formatting. - Refactored index.astro in main pages for improved readability. - Standardized login.astro for better formatting. - Cleaned up not-found.astro for consistent import formatting. - Enhanced [...schem].astro for better readability. - Refactored [mode].astro for consistent import formatting. - Improved [...gamemode].astro for better readability. - Cleaned up [mode].astro in regeln directory for consistent formatting. - Refactored index.astro in regeln directory for improved readability. - Enhanced fight.astro for consistent import formatting.
This commit is contained in:
@@ -1,22 +1,31 @@
|
||||
---
|
||||
|
||||
import {l} from "../util/util";
|
||||
import {capitalize} from "./admin/util";
|
||||
import { l } from "../util/util";
|
||||
import { capitalize } from "./admin/util";
|
||||
|
||||
interface Props {
|
||||
tag: string;
|
||||
noLink?: boolean;
|
||||
}
|
||||
|
||||
const {tag, noLink} = Astro.props;
|
||||
const { tag, noLink } = Astro.props;
|
||||
---
|
||||
|
||||
{noLink
|
||||
? (
|
||||
<span class="inline-block bg-transparent border border-amber-500/30 px-3 py-0.5 text-xs font-semibold text-amber-400 mr-2 uppercase tracking-wider" style="font-family: 'Barlow Condensed', sans-serif;">{capitalize(tag)}</span>
|
||||
)
|
||||
: (
|
||||
{
|
||||
noLink ? (
|
||||
<span
|
||||
class="inline-block bg-transparent border border-amber-500/30 px-3 py-0.5 text-xs font-semibold text-amber-400 mr-2 uppercase tracking-wider"
|
||||
style="font-family: 'Barlow Condensed', sans-serif;"
|
||||
>
|
||||
{capitalize(tag)}
|
||||
</span>
|
||||
) : (
|
||||
<a href={l(`/announcements/tags/${tag}`)}>
|
||||
<span class="inline-block bg-transparent border border-amber-500/30 px-3 py-0.5 text-xs font-semibold text-amber-400 mr-2 uppercase tracking-wider hover:border-amber-400 hover:text-amber-300 transition-colors" style="font-family: 'Barlow Condensed', sans-serif;">{capitalize(tag)}</span>
|
||||
<span
|
||||
class="inline-block bg-transparent border border-amber-500/30 px-3 py-0.5 text-xs font-semibold text-amber-400 mr-2 uppercase tracking-wider hover:border-amber-400 hover:text-amber-300 transition-colors"
|
||||
style="font-family: 'Barlow Condensed', sans-serif;"
|
||||
>
|
||||
{capitalize(tag)}
|
||||
</span>
|
||||
</a>
|
||||
)}
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user