finish all pages
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
---
|
||||
interface Props {
|
||||
size?: "md" | "lg";
|
||||
block?: boolean;
|
||||
style?: "outline" | "primary" | "inverted";
|
||||
class?: string;
|
||||
[x: string]: any;
|
||||
|
||||
1
src/components/ui/icons/index.js
Normal file
1
src/components/ui/icons/index.js
Normal file
@@ -0,0 +1 @@
|
||||
export { default as Tick } from "./tick.astro";
|
||||
16
src/components/ui/icons/tick.astro
Normal file
16
src/components/ui/icons/tick.astro
Normal file
@@ -0,0 +1,16 @@
|
||||
---
|
||||
const { class: className } = Astro.props;
|
||||
---
|
||||
|
||||
<svg
|
||||
class={className}
|
||||
viewBox="0 0 24 24"
|
||||
fill="none"
|
||||
xmlns="http://www.w3.org/2000/svg"
|
||||
><circle cx="12" cy="12" r="9" fill="currentColor" fill-opacity=".16"
|
||||
></circle><path
|
||||
fill-rule="evenodd"
|
||||
clip-rule="evenodd"
|
||||
d="M3.75 12a8.25 8.25 0 0 1 11.916-7.393.75.75 0 1 0 .668-1.343A9.713 9.713 0 0 0 12 2.25c-5.385 0-9.75 4.365-9.75 9.75s4.365 9.75 9.75 9.75 9.75-4.365 9.75-9.75c0-.366-.02-.727-.06-1.082a.75.75 0 1 0-1.49.164A8.25 8.25 0 1 1 3.75 12Zm17.78-6.47a.75.75 0 0 0-1.06-1.06L12 12.94l-2.47-2.47a.75.75 0 0 0-1.06 1.06l3 3a.75.75 0 0 0 1.06 0l9-9Z"
|
||||
fill="currentColor"></path>
|
||||
</svg>
|
||||
@@ -1,7 +1,8 @@
|
||||
---
|
||||
interface Props {
|
||||
href: string;
|
||||
size?: string;
|
||||
size?: "md" | "lg";
|
||||
block?: boolean;
|
||||
style?: "outline" | "primary" | "inverted";
|
||||
class?: string;
|
||||
[x: string]: any;
|
||||
@@ -9,6 +10,7 @@ interface Props {
|
||||
|
||||
const {
|
||||
href,
|
||||
block,
|
||||
size = "lg",
|
||||
style = "primary",
|
||||
class: className,
|
||||
@@ -21,9 +23,8 @@ const sizes = {
|
||||
};
|
||||
|
||||
const styles = {
|
||||
outline: "border-2 border-black hover:bg-black text-black hover:text-white",
|
||||
primary:
|
||||
"bg-black text-white hover:bg-slate-900 border-2 border-transparent",
|
||||
outline: "bg-white border-2 border-black hover:bg-gray-100 text-black ",
|
||||
primary: "bg-black text-white hover:bg-gray-800 border-2 border-transparent",
|
||||
inverted: "bg-white text-black border-2 border-transparent",
|
||||
};
|
||||
---
|
||||
@@ -32,7 +33,8 @@ const styles = {
|
||||
href={href}
|
||||
{...rest}
|
||||
class:list={[
|
||||
" rounded text-center transition focus-visible:ring-2 ring-offset-2 ring-gray-200",
|
||||
"rounded text-center transition focus-visible:ring-2 ring-offset-2 ring-gray-200",
|
||||
block && "w-full",
|
||||
sizes[size],
|
||||
styles[style],
|
||||
className,
|
||||
|
||||
Reference in New Issue
Block a user