Don't use tabs in editor

This commit is contained in:
prototypa
2023-01-09 21:44:06 -05:00
parent 58484dfca8
commit f641767078
56 changed files with 2217 additions and 2203 deletions

View File

@ -4,13 +4,5 @@
"singleQuote": true, "singleQuote": true,
"tabWidth": 2, "tabWidth": 2,
"trailingComma": "es5", "trailingComma": "es5",
"useTabs": true,
"overrides": [
{
"files": [".*", "*.json", "*.md", "*.toml", "*.yml"],
"options": {
"useTabs": false "useTabs": false
} }
}
]
}

View File

@ -157,7 +157,8 @@ const CONFIG = {
language: 'en', // Default language language: 'en', // Default language
textDirection: 'ltr', // Default html text direction textDirection: 'ltr', // Default html text direction
dateFormatter: new Intl.DateTimeFormat('en', { // Date format dateFormatter: new Intl.DateTimeFormat('en', {
// Date format
year: 'numeric', year: 'numeric',
month: 'short', month: 'short',
day: 'numeric', day: 'numeric',

View File

@ -6,5 +6,9 @@ const { title = await Astro.slots.render('default'), subtitle = await Astro.slot
<h1 class="text-4xl md:text-5xl font-bold leading-tighter tracking-tighter font-heading"> <h1 class="text-4xl md:text-5xl font-bold leading-tighter tracking-tighter font-heading">
{title} {title}
</h1> </h1>
{subtitle && <div class="mt-2 md:mt-3 mx-auto text-xl text-gray-500 dark:text-slate-400 font-medium" set:html={subtitle} />} {
subtitle && (
<div class="mt-2 md:mt-3 mx-auto text-xl text-gray-500 dark:text-slate-400 font-medium" set:html={subtitle} />
)
}
</header> </header>

View File

@ -51,10 +51,7 @@ const link = !BLOG?.post?.disabled ? getPermalink(post.slug, 'post') : '';
<h2 class="text-xl sm:text-2xl font-bold leading-tight mb-2 font-heading text-gray-700 dark:text-slate-300"> <h2 class="text-xl sm:text-2xl font-bold leading-tight mb-2 font-heading text-gray-700 dark:text-slate-300">
{ {
link ? ( link ? (
<a <a class="hover:text-primary-800 dark:hover:text-primary-700 transition ease-in duration-200" href={link}>
class="hover:text-primary-800 dark:hover:text-primary-700 transition ease-in duration-200"
href={link}
>
{post.title} {post.title}
</a> </a>
) : ( ) : (
@ -67,7 +64,6 @@ const link = !BLOG?.post?.disabled ? getPermalink(post.slug, 'post') : '';
{post.excerpt && <p class="flex-grow text-gray-500 dark:text-slate-400 text-lg">{post.excerpt}</p>} {post.excerpt && <p class="flex-grow text-gray-500 dark:text-slate-400 text-lg">{post.excerpt}</p>}
<footer class="mt-5"> <footer class="mt-5">
<PostTags tags={post.tags} /> <PostTags tags={post.tags} />
</footer> </footer>
</div> </div>
</article> </article>

View File

@ -33,7 +33,9 @@ const { post, url } = Astro.props;
> >
{post.title} {post.title}
</h1> </h1>
<p class="max-w-3xl mx-auto mt-4 mb-8 px-4 sm:px-6 text-xl md:text-2xl text-gray-500 dark:text-slate-400 font-medium text-justify"> <p
class="max-w-3xl mx-auto mt-4 mb-8 px-4 sm:px-6 text-xl md:text-2xl text-gray-500 dark:text-slate-400 font-medium text-justify"
>
{post.excerpt} {post.excerpt}
</p> </p>

View File

@ -17,7 +17,16 @@ const { tags, class: className = 'text-sm' } = Astro.props;
<ul class={className}> <ul class={className}>
{tags.map((tag) => ( {tags.map((tag) => (
<li class="bg-gray-100 dark:bg-slate-700 inline-block mr-2 mb-2 py-0.5 px-2 lowercase font-medium"> <li class="bg-gray-100 dark:bg-slate-700 inline-block mr-2 mb-2 py-0.5 px-2 lowercase font-medium">
{BLOG?.tag?.disabled ? tag : <a href={getPermalink(tag, 'tag')} class="text-gray-600 dark:text-slate-300 hover:text-primary-800 dark:hover:text-gray-200">{tag}</a>} {BLOG?.tag?.disabled ? (
tag
) : (
<a
href={getPermalink(tag, 'tag')}
class="text-gray-600 dark:text-slate-300 hover:text-primary-800 dark:hover:text-gray-200"
>
{tag}
</a>
)}
</li> </li>
))} ))}
</ul> </ul>

View File

@ -23,7 +23,9 @@ const {
<section class="relative"> <section class="relative">
<div class="max-w-6xl mx-auto px-4 sm:px-6"> <div class="max-w-6xl mx-auto px-4 sm:px-6">
<div class="py-12 md:py-20"> <div class="py-12 md:py-20">
<div class="max-w-3xl mx-auto text-center p-6 rounded-md shadow-xl dark:shadow-none dark:border dark:border-slate-600"> <div
class="max-w-3xl mx-auto text-center p-6 rounded-md shadow-xl dark:shadow-none dark:border dark:border-slate-600"
>
{ {
title && ( title && (
<h2 <h2

View File

@ -1,5 +1,5 @@
--- ---
import Icon from "astro-icon" import Icon from 'astro-icon';
import { Picture } from '@astrojs/image/components'; import { Picture } from '@astrojs/image/components';
interface Item { interface Item {
@ -68,7 +68,7 @@ const {
<div class="flex"> <div class="flex">
<div class="flex-shrink-0"> <div class="flex-shrink-0">
<div class="flex h-7 w-7 items-center justify-center rounded-full bg-blue-800 text-gray-50"> <div class="flex h-7 w-7 items-center justify-center rounded-full bg-blue-800 text-gray-50">
<Icon name={icon? icon : "tabler:check"} class="w-5 h-5" /> <Icon name={icon ? icon : 'tabler:check'} class="w-5 h-5" />
</div> </div>
</div> </div>
<div class="ml-4"> <div class="ml-4">

View File

@ -43,7 +43,10 @@ const {
)} )}
{subtitle && ( {subtitle && (
<p class="max-w-3xl mx-auto sm:text-center text-xl text-gray-600 dark:text-slate-400" set:html={subtitle} /> <p
class="max-w-3xl mx-auto sm:text-center text-xl text-gray-600 dark:text-slate-400"
set:html={subtitle}
/>
)} )}
</div> </div>
) )

View File

@ -12,19 +12,19 @@ const links = [
links: [ links: [
{ {
text: 'Features', text: 'Features',
href: "#", href: '#',
}, },
{ {
text: 'Pricing', text: 'Pricing',
href: "#", href: '#',
}, },
{ {
text: 'About us', text: 'About us',
href: "#", href: '#',
}, },
{ {
text: 'Contact', text: 'Contact',
href: "#", href: '#',
}, },
{ {
text: 'Terms', text: 'Terms',

View File

@ -47,7 +47,11 @@ const {
<Fragment set:html={callToAction} /> <Fragment set:html={callToAction} />
) : ( ) : (
<a class="btn btn-primary sm:mb-0 w-full" href={callToAction?.href} target="_blank" rel="noopener"> <a class="btn btn-primary sm:mb-0 w-full" href={callToAction?.href} target="_blank" rel="noopener">
{callToAction?.icon && <><Icon name={callToAction.icon} class="w-5 h-5 mr-1 -ml-1.5" />{' '}</>} {callToAction?.icon && (
<>
<Icon name={callToAction.icon} class="w-5 h-5 mr-1 -ml-1.5" />{' '}
</>
)}
{callToAction?.text} {callToAction?.text}
</a> </a>
)} )}
@ -61,7 +65,11 @@ const {
<Fragment set:html={callToAction2} /> <Fragment set:html={callToAction2} />
) : ( ) : (
<a class="btn w-full" href={callToAction2?.href}> <a class="btn w-full" href={callToAction2?.href}>
{callToAction2?.icon && <><Icon name={callToAction2.icon} class="w-5 h-5 mr-1 -ml-1.5" />{' '}</>} {callToAction2?.icon && (
<>
<Icon name={callToAction2.icon} class="w-5 h-5 mr-1 -ml-1.5" />{' '}
</>
)}
{callToAction2.text} {callToAction2.text}
</a> </a>
)} )}

View File

@ -44,7 +44,9 @@ const {
{ {
items.map(({ name, value }) => ( items.map(({ name, value }) => (
<div class="text-center md:border-r md:last:border-none dark:md:border-slate-500 mb-12 md:mb-0"> <div class="text-center md:border-r md:last:border-none dark:md:border-slate-500 mb-12 md:mb-0">
<div class="text-[2.6rem] font-bold lg:text-5xl xl:text-6xl text-primary-800 dark:text-primary-600 font-heading">{value}</div> <div class="text-[2.6rem] font-bold lg:text-5xl xl:text-6xl text-primary-800 dark:text-primary-600 font-heading">
{value}
</div>
<p class="text-sm font-medium tracking-widest text-gray-800 dark:text-slate-400 uppercase lg:text-base"> <p class="text-sm font-medium tracking-widest text-gray-800 dark:text-slate-400 uppercase lg:text-base">
{name} {name}
</p> </p>

View File

@ -8,7 +8,8 @@ const CONFIG = {
trailingSlash: false, trailingSlash: false,
title: 'AstroWind — Free template for create a website with Astro + Tailwind CSS', title: 'AstroWind — Free template for create a website with Astro + Tailwind CSS',
description: '🚀 Suitable for Startups, Small Business, Sass Websites, Professional Portfolios, Marketing Websites, Landing Pages & Blogs.', description:
'🚀 Suitable for Startups, Small Business, Sass Websites, Professional Portfolios, Marketing Websites, Landing Pages & Blogs.',
defaultImage: defaultImage, defaultImage: defaultImage,
defaultTheme: 'system', // Values: "system" | "light" | "dark" | "light:only" | "dark:only" defaultTheme: 'system', // Values: "system" | "light" | "dark" | "light:only" | "dark:only"

View File

@ -9,9 +9,7 @@ const blog = defineCollection({
canonical: z.string().url().optional(), canonical: z.string().url().optional(),
permalink: z.string().optional(), permalink: z.string().optional(),
publishDate: z publishDate: z.date().or(z.string()).optional(),
.date().or(z.string())
.optional(),
draft: z.boolean().optional(), draft: z.boolean().optional(),
excerpt: z.string().optional(), excerpt: z.string().optional(),

View File

@ -30,7 +30,9 @@ const meta = {
<Layout {meta}> <Layout {meta}>
<section class="px-6 sm:px-6 py-12 sm:py-16 lg:py-20 mx-auto max-w-4xl"> <section class="px-6 sm:px-6 py-12 sm:py-16 lg:py-20 mx-auto max-w-4xl">
<Headline subtitle="A statically generated blog example with news, tutorials, resources and other interesting content related to AstroWind"> <Headline
subtitle="A statically generated blog example with news, tutorials, resources and other interesting content related to AstroWind"
>
The Blog The Blog
</Headline> </Headline>
<BlogList posts={page.data} /> <BlogList posts={page.data} />

View File

@ -135,27 +135,21 @@ const meta = {
items={[ items={[
{ {
title: 'Per ei quaeque sensibus', title: 'Per ei quaeque sensibus',
}, },
{ {
title: 'Cu imperdiet posidonium sed', title: 'Cu imperdiet posidonium sed',
}, },
{ {
title: 'Nulla omittam sadipscing mel ne', title: 'Nulla omittam sadipscing mel ne',
}, },
{ {
title: 'Per ei quaeque sensibus', title: 'Per ei quaeque sensibus',
}, },
{ {
title: 'Cu imperdiet posidonium sed', title: 'Cu imperdiet posidonium sed',
}, },
{ {
title: 'Nulla omittam sadipscing mel ne', title: 'Nulla omittam sadipscing mel ne',
}, },
]} ]}
image={{ image={{

View File

@ -6,7 +6,7 @@ const formatter =
year: 'numeric', year: 'numeric',
month: 'short', month: 'short',
day: 'numeric', day: 'numeric',
timeZone: 'UTC' timeZone: 'UTC',
}); });
/* eslint-disable no-mixed-spaces-and-tabs */ /* eslint-disable no-mixed-spaces-and-tabs */