Skip to content

Commit 14dcdcf

Browse files
committed
Rename 'check' to 'check-stylized' for Marker icon to avoid conflict when merging all icons in.
1 parent bbfad7e commit 14dcdcf

4 files changed

Lines changed: 13 additions & 5 deletions

File tree

src/components/List/layouts/CheckIconsList.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ const emClass = ["text-content font-semibold not-italic", classes?.em]
2626
items.map((item) => (
2727
<li class:list={liClass}>
2828
<Marker
29-
icon="check"
29+
icon="check-stylized"
3030
color={"text-success"}
3131
size={5}
3232
classes={"mt-1"}

src/components/List/layouts/TwoColumnCheckIconsList.astro

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ const liClass = ["flex items-center gap-2", classes?.li]
2525
items.map((item) => (
2626
<li class:list={liClass}>
2727
<Marker
28-
icon="check"
28+
icon="check-stylized"
2929
color={"text-success"}
3030
size={size ?? 5}
3131
/>
File renamed without changes.

src/components/Marker/index.astro

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -6,18 +6,26 @@ export type Props = {
66
icon: string
77
/**
88
* The name of a Tailwind theme color CSS variable without the `--theme-color-` prefix.
9-
* Example: 'primary', 'text-content', 'green-500'
9+
* Example: 'primary', 'text-content', 'green-500'. Defaults to "inherit". Icon files
10+
* apply the value to their stroke and fill attributes as appropriate for the image.
1011
*/
1112
color?: string
12-
/** Defaults to 24 on Icon. Otherwise varies a good bit. */
13+
/** Defaults to 24. */
1314
size?: number
15+
/** Any additional CSS classes to apply to the SVG element. */
1416
classes?: string
17+
/**
18+
* Whether the icon has a <title> element and aria-hidden=false attribute (if true),
19+
* or aria-hidden=true without a <title> (if false). Defaults to false.
20+
*/
1521
accessible?: boolean
22+
/** Whether the icon can receive focus. Defaults to false. */
1623
focusable?: boolean
24+
/** Whether the icon is used as a list marker. If true, applies a "mt-0.5" class. Defaults to true. */
1725
isListMarker?: boolean
1826
}
1927
20-
const { icon, color, size, classes, accessible = false, focusable = false, isListMarker = true }: Props = Astro.props
28+
const { icon, color = 'inherit', size = 24, classes, accessible = false, focusable = false, isListMarker = true }: Props = Astro.props
2129
2230
const MarkerComponent = getMarkerComponent(icon) as unknown as (_props: {
2331
color?: string

0 commit comments

Comments
 (0)