@slipstream-ui/core 0.11.0 → 0.11.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.mts +31 -6
- package/dist/index.d.ts +31 -6
- package/dist/index.js +17 -4
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +17 -4
- package/dist/index.mjs.map +1 -1
- package/dist/manifests/accordion.manifest.json +1 -1
- package/dist/manifests/alert.manifest.json +1 -1
- package/dist/manifests/announcement-bar.manifest.json +1 -1
- package/dist/manifests/app-shell.manifest.json +1 -1
- package/dist/manifests/applied-filters.manifest.json +1 -1
- package/dist/manifests/article-card.manifest.json +1 -1
- package/dist/manifests/auth-layout.manifest.json +1 -1
- package/dist/manifests/autocomplete.manifest.json +1 -1
- package/dist/manifests/avatar.manifest.json +1 -1
- package/dist/manifests/badge.manifest.json +1 -1
- package/dist/manifests/block.manifest.json +1 -1
- package/dist/manifests/bottom-nav.manifest.json +1 -1
- package/dist/manifests/breadcrumb.manifest.json +1 -1
- package/dist/manifests/button-group.manifest.json +1 -1
- package/dist/manifests/button.manifest.json +1 -1
- package/dist/manifests/calendar.manifest.json +1 -1
- package/dist/manifests/card.manifest.json +1 -1
- package/dist/manifests/checkbox.manifest.json +1 -1
- package/dist/manifests/comparison-table.manifest.json +1 -1
- package/dist/manifests/confirm-dialog.manifest.json +1 -1
- package/dist/manifests/contact-strip.manifest.json +1 -1
- package/dist/manifests/container.manifest.json +1 -1
- package/dist/manifests/cta-section.manifest.json +1 -1
- package/dist/manifests/data-table.manifest.json +1 -1
- package/dist/manifests/date-picker-popover.manifest.json +1 -1
- package/dist/manifests/date-picker.manifest.json +1 -1
- package/dist/manifests/date-range-picker.manifest.json +1 -1
- package/dist/manifests/deal-card.manifest.json +1 -1
- package/dist/manifests/dialog.manifest.json +1 -1
- package/dist/manifests/document-card.manifest.json +1 -1
- package/dist/manifests/drawer.manifest.json +1 -1
- package/dist/manifests/empty-state.manifest.json +1 -1
- package/dist/manifests/entity-card.manifest.json +9 -3
- package/dist/manifests/feature-grid.manifest.json +1 -1
- package/dist/manifests/feature-row.manifest.json +1 -1
- package/dist/manifests/fieldset.manifest.json +1 -1
- package/dist/manifests/file-upload.manifest.json +1 -1
- package/dist/manifests/filter-bar.manifest.json +1 -1
- package/dist/manifests/filter-chips.manifest.json +1 -1
- package/dist/manifests/filter-panel.manifest.json +1 -1
- package/dist/manifests/flex.manifest.json +1 -1
- package/dist/manifests/form-field.manifest.json +1 -1
- package/dist/manifests/form-layout.manifest.json +1 -1
- package/dist/manifests/form.manifest.json +1 -1
- package/dist/manifests/grid.manifest.json +1 -1
- package/dist/manifests/heading.manifest.json +1 -1
- package/dist/manifests/hero.manifest.json +1 -1
- package/dist/manifests/image.manifest.json +1 -1
- package/dist/manifests/input-group.manifest.json +1 -1
- package/dist/manifests/input.manifest.json +1 -1
- package/dist/manifests/label.manifest.json +1 -1
- package/dist/manifests/link-tabs.manifest.json +1 -1
- package/dist/manifests/link.manifest.json +1 -1
- package/dist/manifests/list.manifest.json +1 -1
- package/dist/manifests/load-more.manifest.json +1 -1
- package/dist/manifests/logo-cloud.manifest.json +1 -1
- package/dist/manifests/menu.manifest.json +1 -1
- package/dist/manifests/metric-card.manifest.json +1 -1
- package/dist/manifests/multi-select.manifest.json +1 -1
- package/dist/manifests/newsletter.manifest.json +1 -1
- package/dist/manifests/page-header.manifest.json +5 -5
- package/dist/manifests/pagination.manifest.json +1 -1
- package/dist/manifests/password-input.manifest.json +1 -1
- package/dist/manifests/popover.manifest.json +1 -1
- package/dist/manifests/process-steps.manifest.json +1 -1
- package/dist/manifests/progress.manifest.json +1 -1
- package/dist/manifests/prose.manifest.json +1 -1
- package/dist/manifests/radio.manifest.json +1 -1
- package/dist/manifests/range-slider.manifest.json +1 -1
- package/dist/manifests/search.manifest.json +1 -1
- package/dist/manifests/section-heading.manifest.json +3 -3
- package/dist/manifests/section.manifest.json +1 -1
- package/dist/manifests/segmented-control.manifest.json +1 -1
- package/dist/manifests/select-menu.manifest.json +1 -1
- package/dist/manifests/select.manifest.json +1 -1
- package/dist/manifests/separator.manifest.json +1 -1
- package/dist/manifests/site-footer.manifest.json +1 -1
- package/dist/manifests/site-header.manifest.json +1 -1
- package/dist/manifests/skeleton.manifest.json +1 -1
- package/dist/manifests/spinner.manifest.json +1 -1
- package/dist/manifests/stat-band.manifest.json +1 -1
- package/dist/manifests/stepper.manifest.json +1 -1
- package/dist/manifests/switch.manifest.json +1 -1
- package/dist/manifests/table-card.manifest.json +1 -1
- package/dist/manifests/table-of-contents.manifest.json +1 -1
- package/dist/manifests/table.manifest.json +1 -1
- package/dist/manifests/tabs.manifest.json +1 -1
- package/dist/manifests/testimonial.manifest.json +1 -1
- package/dist/manifests/text.manifest.json +1 -1
- package/dist/manifests/textarea.manifest.json +1 -1
- package/dist/manifests/theme-toggle.manifest.json +1 -1
- package/dist/manifests/time-picker.manifest.json +1 -1
- package/dist/manifests/timeline.manifest.json +1 -1
- package/dist/manifests/toast.manifest.json +1 -1
- package/dist/manifests/tombstone-card.manifest.json +1 -1
- package/dist/manifests/tooltip.manifest.json +1 -1
- package/dist/src/components/entity-card/EntityCard.d.ts +21 -0
- package/dist/src/components/entity-card/EntityCard.js +17 -4
- package/dist/src/components/entity-card/EntityCard.js.map +1 -1
- package/dist/src/components/entity-card/EntityCard.mjs +17 -4
- package/dist/src/components/entity-card/EntityCard.mjs.map +1 -1
- package/dist/src/components/page-header/PageHeader.d.ts +6 -4
- package/dist/src/components/page-header/PageHeader.js.map +1 -1
- package/dist/src/components/page-header/PageHeader.mjs.map +1 -1
- package/dist/src/components/section-heading/SectionHeading.d.ts +4 -2
- package/dist/src/components/section-heading/SectionHeading.js.map +1 -1
- package/dist/src/components/section-heading/SectionHeading.mjs.map +1 -1
- package/dist/styles-full.css +1 -1
- package/dist/styles.css +1 -1
- package/package.json +3 -3
- package/src/components/entity-card/EntityCard.test.tsx +27 -0
- package/src/components/entity-card/EntityCard.tsx +22 -6
- package/src/components/page-header/PageHeader.test.tsx +16 -0
- package/src/components/page-header/PageHeader.tsx +3 -2
- package/src/components/section-heading/SectionHeading.test.tsx +16 -0
- package/src/components/section-heading/SectionHeading.tsx +2 -1
- package/src/manifests/accordion.manifest.json +1 -1
- package/src/manifests/alert.manifest.json +1 -1
- package/src/manifests/announcement-bar.manifest.json +1 -1
- package/src/manifests/app-shell.manifest.json +1 -1
- package/src/manifests/applied-filters.manifest.json +1 -1
- package/src/manifests/article-card.manifest.json +1 -1
- package/src/manifests/auth-layout.manifest.json +1 -1
- package/src/manifests/autocomplete.manifest.json +1 -1
- package/src/manifests/avatar.manifest.json +1 -1
- package/src/manifests/badge.manifest.json +1 -1
- package/src/manifests/block.manifest.json +1 -1
- package/src/manifests/bottom-nav.manifest.json +1 -1
- package/src/manifests/breadcrumb.manifest.json +1 -1
- package/src/manifests/button-group.manifest.json +1 -1
- package/src/manifests/button.manifest.json +1 -1
- package/src/manifests/calendar.manifest.json +1 -1
- package/src/manifests/card.manifest.json +1 -1
- package/src/manifests/checkbox.manifest.json +1 -1
- package/src/manifests/comparison-table.manifest.json +1 -1
- package/src/manifests/confirm-dialog.manifest.json +1 -1
- package/src/manifests/contact-strip.manifest.json +1 -1
- package/src/manifests/container.manifest.json +1 -1
- package/src/manifests/cta-section.manifest.json +1 -1
- package/src/manifests/data-table.manifest.json +1 -1
- package/src/manifests/date-picker-popover.manifest.json +1 -1
- package/src/manifests/date-picker.manifest.json +1 -1
- package/src/manifests/date-range-picker.manifest.json +1 -1
- package/src/manifests/deal-card.manifest.json +1 -1
- package/src/manifests/dialog.manifest.json +1 -1
- package/src/manifests/document-card.manifest.json +1 -1
- package/src/manifests/drawer.manifest.json +1 -1
- package/src/manifests/empty-state.manifest.json +1 -1
- package/src/manifests/entity-card.manifest.json +9 -3
- package/src/manifests/feature-grid.manifest.json +1 -1
- package/src/manifests/feature-row.manifest.json +1 -1
- package/src/manifests/fieldset.manifest.json +1 -1
- package/src/manifests/file-upload.manifest.json +1 -1
- package/src/manifests/filter-bar.manifest.json +1 -1
- package/src/manifests/filter-chips.manifest.json +1 -1
- package/src/manifests/filter-panel.manifest.json +1 -1
- package/src/manifests/flex.manifest.json +1 -1
- package/src/manifests/form-field.manifest.json +1 -1
- package/src/manifests/form-layout.manifest.json +1 -1
- package/src/manifests/form.manifest.json +1 -1
- package/src/manifests/grid.manifest.json +1 -1
- package/src/manifests/heading.manifest.json +1 -1
- package/src/manifests/hero.manifest.json +1 -1
- package/src/manifests/image.manifest.json +1 -1
- package/src/manifests/input-group.manifest.json +1 -1
- package/src/manifests/input.manifest.json +1 -1
- package/src/manifests/label.manifest.json +1 -1
- package/src/manifests/link-tabs.manifest.json +1 -1
- package/src/manifests/link.manifest.json +1 -1
- package/src/manifests/list.manifest.json +1 -1
- package/src/manifests/load-more.manifest.json +1 -1
- package/src/manifests/logo-cloud.manifest.json +1 -1
- package/src/manifests/menu.manifest.json +1 -1
- package/src/manifests/metric-card.manifest.json +1 -1
- package/src/manifests/multi-select.manifest.json +1 -1
- package/src/manifests/newsletter.manifest.json +1 -1
- package/src/manifests/page-header.manifest.json +5 -5
- package/src/manifests/pagination.manifest.json +1 -1
- package/src/manifests/password-input.manifest.json +1 -1
- package/src/manifests/popover.manifest.json +1 -1
- package/src/manifests/process-steps.manifest.json +1 -1
- package/src/manifests/progress.manifest.json +1 -1
- package/src/manifests/prose.manifest.json +1 -1
- package/src/manifests/radio.manifest.json +1 -1
- package/src/manifests/range-slider.manifest.json +1 -1
- package/src/manifests/search.manifest.json +1 -1
- package/src/manifests/section-heading.manifest.json +3 -3
- package/src/manifests/section.manifest.json +1 -1
- package/src/manifests/segmented-control.manifest.json +1 -1
- package/src/manifests/select-menu.manifest.json +1 -1
- package/src/manifests/select.manifest.json +1 -1
- package/src/manifests/separator.manifest.json +1 -1
- package/src/manifests/site-footer.manifest.json +1 -1
- package/src/manifests/site-header.manifest.json +1 -1
- package/src/manifests/skeleton.manifest.json +1 -1
- package/src/manifests/spinner.manifest.json +1 -1
- package/src/manifests/stat-band.manifest.json +1 -1
- package/src/manifests/stepper.manifest.json +1 -1
- package/src/manifests/switch.manifest.json +1 -1
- package/src/manifests/table-card.manifest.json +1 -1
- package/src/manifests/table-of-contents.manifest.json +1 -1
- package/src/manifests/table.manifest.json +1 -1
- package/src/manifests/tabs.manifest.json +1 -1
- package/src/manifests/testimonial.manifest.json +1 -1
- package/src/manifests/text.manifest.json +1 -1
- package/src/manifests/textarea.manifest.json +1 -1
- package/src/manifests/theme-toggle.manifest.json +1 -1
- package/src/manifests/time-picker.manifest.json +1 -1
- package/src/manifests/timeline.manifest.json +1 -1
- package/src/manifests/toast.manifest.json +1 -1
- package/src/manifests/tombstone-card.manifest.json +1 -1
- package/src/manifests/tooltip.manifest.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -2118,9 +2118,10 @@ declare const EmptyState: React.ForwardRefExoticComponent<React.HTMLAttributes<H
|
|
|
2118
2118
|
|
|
2119
2119
|
type PageHeaderProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
2120
2120
|
title: string;
|
|
2121
|
-
|
|
2121
|
+
/** Supporting summary under the title; accepts links and inline markup. */
|
|
2122
|
+
description?: React.ReactNode;
|
|
2122
2123
|
/** Alias for `description` (migration-friendly). */
|
|
2123
|
-
subtitle?:
|
|
2124
|
+
subtitle?: React.ReactNode;
|
|
2124
2125
|
/** Breadcrumbs/eyebrow above the title. */
|
|
2125
2126
|
breadcrumbs?: React.ReactNode;
|
|
2126
2127
|
/** Right-aligned actions (buttons, menus). */
|
|
@@ -2147,9 +2148,10 @@ type PageHeaderProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
2147
2148
|
*/
|
|
2148
2149
|
declare const PageHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & {
|
|
2149
2150
|
title: string;
|
|
2150
|
-
|
|
2151
|
+
/** Supporting summary under the title; accepts links and inline markup. */
|
|
2152
|
+
description?: React.ReactNode;
|
|
2151
2153
|
/** Alias for `description` (migration-friendly). */
|
|
2152
|
-
subtitle?:
|
|
2154
|
+
subtitle?: React.ReactNode;
|
|
2153
2155
|
/** Breadcrumbs/eyebrow above the title. */
|
|
2154
2156
|
breadcrumbs?: React.ReactNode;
|
|
2155
2157
|
/** Right-aligned actions (buttons, menus). */
|
|
@@ -2198,7 +2200,8 @@ declare function documentHead({ title, description, canonical, noindex, }: Docum
|
|
|
2198
2200
|
|
|
2199
2201
|
type SectionHeadingProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
2200
2202
|
title: string;
|
|
2201
|
-
|
|
2203
|
+
/** Supporting copy under the title; accepts links and inline markup. */
|
|
2204
|
+
description?: React.ReactNode;
|
|
2202
2205
|
/** Kicker above the title (category, step, overline). */
|
|
2203
2206
|
eyebrow?: React.ReactNode;
|
|
2204
2207
|
/** Right-aligned actions (link to all, buttons). */
|
|
@@ -2221,7 +2224,8 @@ type SectionHeadingProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
2221
2224
|
*/
|
|
2222
2225
|
declare const SectionHeading: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & {
|
|
2223
2226
|
title: string;
|
|
2224
|
-
|
|
2227
|
+
/** Supporting copy under the title; accepts links and inline markup. */
|
|
2228
|
+
description?: React.ReactNode;
|
|
2225
2229
|
/** Kicker above the title (category, step, overline). */
|
|
2226
2230
|
eyebrow?: React.ReactNode;
|
|
2227
2231
|
/** Right-aligned actions (link to all, buttons). */
|
|
@@ -3560,6 +3564,13 @@ type EntityCardProps = React.HTMLAttributes<HTMLElement> & {
|
|
|
3560
3564
|
tags?: string[];
|
|
3561
3565
|
/** Profile destination. */
|
|
3562
3566
|
href?: string;
|
|
3567
|
+
/**
|
|
3568
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3569
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3570
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3571
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3572
|
+
*/
|
|
3573
|
+
cardHref?: string;
|
|
3563
3574
|
/** Custom link element for routers. */
|
|
3564
3575
|
linkComponent?: React.ElementType;
|
|
3565
3576
|
/** Extra footer actions. */
|
|
@@ -3587,6 +3598,13 @@ declare const EntityCard: React.ForwardRefExoticComponent<React.HTMLAttributes<H
|
|
|
3587
3598
|
tags?: string[];
|
|
3588
3599
|
/** Profile destination. */
|
|
3589
3600
|
href?: string;
|
|
3601
|
+
/**
|
|
3602
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3603
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3604
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3605
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3606
|
+
*/
|
|
3607
|
+
cardHref?: string;
|
|
3590
3608
|
/** Custom link element for routers. */
|
|
3591
3609
|
linkComponent?: React.ElementType;
|
|
3592
3610
|
/** Extra footer actions. */
|
|
@@ -3610,6 +3628,13 @@ declare const ProfileCard: React.ForwardRefExoticComponent<React.HTMLAttributes<
|
|
|
3610
3628
|
tags?: string[];
|
|
3611
3629
|
/** Profile destination. */
|
|
3612
3630
|
href?: string;
|
|
3631
|
+
/**
|
|
3632
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3633
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3634
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3635
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3636
|
+
*/
|
|
3637
|
+
cardHref?: string;
|
|
3613
3638
|
/** Custom link element for routers. */
|
|
3614
3639
|
linkComponent?: React.ElementType;
|
|
3615
3640
|
/** Extra footer actions. */
|
package/dist/index.d.ts
CHANGED
|
@@ -2118,9 +2118,10 @@ declare const EmptyState: React.ForwardRefExoticComponent<React.HTMLAttributes<H
|
|
|
2118
2118
|
|
|
2119
2119
|
type PageHeaderProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
2120
2120
|
title: string;
|
|
2121
|
-
|
|
2121
|
+
/** Supporting summary under the title; accepts links and inline markup. */
|
|
2122
|
+
description?: React.ReactNode;
|
|
2122
2123
|
/** Alias for `description` (migration-friendly). */
|
|
2123
|
-
subtitle?:
|
|
2124
|
+
subtitle?: React.ReactNode;
|
|
2124
2125
|
/** Breadcrumbs/eyebrow above the title. */
|
|
2125
2126
|
breadcrumbs?: React.ReactNode;
|
|
2126
2127
|
/** Right-aligned actions (buttons, menus). */
|
|
@@ -2147,9 +2148,10 @@ type PageHeaderProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
2147
2148
|
*/
|
|
2148
2149
|
declare const PageHeader: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & {
|
|
2149
2150
|
title: string;
|
|
2150
|
-
|
|
2151
|
+
/** Supporting summary under the title; accepts links and inline markup. */
|
|
2152
|
+
description?: React.ReactNode;
|
|
2151
2153
|
/** Alias for `description` (migration-friendly). */
|
|
2152
|
-
subtitle?:
|
|
2154
|
+
subtitle?: React.ReactNode;
|
|
2153
2155
|
/** Breadcrumbs/eyebrow above the title. */
|
|
2154
2156
|
breadcrumbs?: React.ReactNode;
|
|
2155
2157
|
/** Right-aligned actions (buttons, menus). */
|
|
@@ -2198,7 +2200,8 @@ declare function documentHead({ title, description, canonical, noindex, }: Docum
|
|
|
2198
2200
|
|
|
2199
2201
|
type SectionHeadingProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
2200
2202
|
title: string;
|
|
2201
|
-
|
|
2203
|
+
/** Supporting copy under the title; accepts links and inline markup. */
|
|
2204
|
+
description?: React.ReactNode;
|
|
2202
2205
|
/** Kicker above the title (category, step, overline). */
|
|
2203
2206
|
eyebrow?: React.ReactNode;
|
|
2204
2207
|
/** Right-aligned actions (link to all, buttons). */
|
|
@@ -2221,7 +2224,8 @@ type SectionHeadingProps = React.HTMLAttributes<HTMLDivElement> & {
|
|
|
2221
2224
|
*/
|
|
2222
2225
|
declare const SectionHeading: React.ForwardRefExoticComponent<React.HTMLAttributes<HTMLDivElement> & {
|
|
2223
2226
|
title: string;
|
|
2224
|
-
|
|
2227
|
+
/** Supporting copy under the title; accepts links and inline markup. */
|
|
2228
|
+
description?: React.ReactNode;
|
|
2225
2229
|
/** Kicker above the title (category, step, overline). */
|
|
2226
2230
|
eyebrow?: React.ReactNode;
|
|
2227
2231
|
/** Right-aligned actions (link to all, buttons). */
|
|
@@ -3560,6 +3564,13 @@ type EntityCardProps = React.HTMLAttributes<HTMLElement> & {
|
|
|
3560
3564
|
tags?: string[];
|
|
3561
3565
|
/** Profile destination. */
|
|
3562
3566
|
href?: string;
|
|
3567
|
+
/**
|
|
3568
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3569
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3570
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3571
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3572
|
+
*/
|
|
3573
|
+
cardHref?: string;
|
|
3563
3574
|
/** Custom link element for routers. */
|
|
3564
3575
|
linkComponent?: React.ElementType;
|
|
3565
3576
|
/** Extra footer actions. */
|
|
@@ -3587,6 +3598,13 @@ declare const EntityCard: React.ForwardRefExoticComponent<React.HTMLAttributes<H
|
|
|
3587
3598
|
tags?: string[];
|
|
3588
3599
|
/** Profile destination. */
|
|
3589
3600
|
href?: string;
|
|
3601
|
+
/**
|
|
3602
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3603
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3604
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3605
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3606
|
+
*/
|
|
3607
|
+
cardHref?: string;
|
|
3590
3608
|
/** Custom link element for routers. */
|
|
3591
3609
|
linkComponent?: React.ElementType;
|
|
3592
3610
|
/** Extra footer actions. */
|
|
@@ -3610,6 +3628,13 @@ declare const ProfileCard: React.ForwardRefExoticComponent<React.HTMLAttributes<
|
|
|
3610
3628
|
tags?: string[];
|
|
3611
3629
|
/** Profile destination. */
|
|
3612
3630
|
href?: string;
|
|
3631
|
+
/**
|
|
3632
|
+
* Makes the whole card a single link (stretched-link pattern): the name
|
|
3633
|
+
* becomes the link and its overlay covers the card, so one target gets one
|
|
3634
|
+
* hover state and one focus ring. Interactive `actions` stay clickable above
|
|
3635
|
+
* the overlay; the redundant footer "View profile" link is suppressed.
|
|
3636
|
+
*/
|
|
3637
|
+
cardHref?: string;
|
|
3613
3638
|
/** Custom link element for routers. */
|
|
3614
3639
|
linkComponent?: React.ElementType;
|
|
3615
3640
|
/** Extra footer actions. */
|
package/dist/index.js
CHANGED
|
@@ -7176,17 +7176,30 @@ var EntityCard = React86.forwardRef(function EntityCard2({
|
|
|
7176
7176
|
stats,
|
|
7177
7177
|
tags,
|
|
7178
7178
|
href,
|
|
7179
|
+
cardHref,
|
|
7179
7180
|
linkComponent,
|
|
7180
7181
|
actions,
|
|
7181
7182
|
className,
|
|
7182
7183
|
...props
|
|
7183
7184
|
}, ref) {
|
|
7184
7185
|
const Link3 = linkComponent ?? "a";
|
|
7185
|
-
|
|
7186
|
+
const stretched = Boolean(cardHref);
|
|
7187
|
+
const nameHref = cardHref ?? href;
|
|
7188
|
+
return /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(Card, { ref, className: cn("flex h-full flex-col", stretched && "relative isolate", className), ...props, children: [
|
|
7186
7189
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(CardHeader, { className: "flex-row items-start gap-3 p-5 pb-3", children: [
|
|
7187
7190
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("div", { className: "shrink-0", children: logo ?? /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(Avatar, { children: /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(AvatarFallback, { children: initials(name) }) }) }),
|
|
7188
7191
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsxs)("div", { className: "min-w-0 flex-1", children: [
|
|
7189
|
-
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("h3", { className: "truncate text-base font-semibold tracking-tight", children:
|
|
7192
|
+
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("h3", { className: "truncate text-base font-semibold tracking-tight", children: nameHref ? /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
7193
|
+
Link3,
|
|
7194
|
+
{
|
|
7195
|
+
href: nameHref,
|
|
7196
|
+
className: cn(
|
|
7197
|
+
"rounded-sm hover:text-primary-ink focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring",
|
|
7198
|
+
stretched && 'after:absolute after:inset-0 after:content-[""]'
|
|
7199
|
+
),
|
|
7200
|
+
children: name
|
|
7201
|
+
}
|
|
7202
|
+
) : name }),
|
|
7190
7203
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("p", { className: "mt-0.5 truncate text-xs text-muted-foreground", children: entityType }),
|
|
7191
7204
|
location && /* @__PURE__ */ (0, import_jsx_runtime86.jsx)("p", { className: "mt-0.5 truncate text-xs text-muted-foreground", children: location })
|
|
7192
7205
|
] })
|
|
@@ -7199,8 +7212,8 @@ var EntityCard = React86.forwardRef(function EntityCard2({
|
|
|
7199
7212
|
/* @__PURE__ */ (0, import_jsx_runtime86.jsx)("dd", { className: "mt-0.5 truncate text-sm font-semibold tabular-nums", children: stat.value })
|
|
7200
7213
|
] }, stat.label)) })
|
|
7201
7214
|
] }),
|
|
7202
|
-
(href || actions) && /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(CardFooter, { className: "flex flex-wrap items-center gap-2 border-t border-border px-5 py-3", children: [
|
|
7203
|
-
href && /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
7215
|
+
(href && !stretched || actions) && /* @__PURE__ */ (0, import_jsx_runtime86.jsxs)(CardFooter, { className: cn("flex flex-wrap items-center gap-2 border-t border-border px-5 py-3", stretched && "relative z-10"), children: [
|
|
7216
|
+
href && !stretched && /* @__PURE__ */ (0, import_jsx_runtime86.jsx)(
|
|
7204
7217
|
Link3,
|
|
7205
7218
|
{
|
|
7206
7219
|
href,
|