-
+
{PromoData.slice(0, 4).map(({ id, link, title, image, alt }) => (
-
-
-
- More info
-
-
+
))}
diff --git a/package.json b/package.json
index 7d0fa35ac..6d3e11a9b 100644
--- a/package.json
+++ b/package.json
@@ -71,8 +71,6 @@
"yup": "1.7.1"
},
"devDependencies": {
- "@commitlint/cli": "20.4.1",
- "@commitlint/config-conventional": "20.4.1",
"@cypress/react": "9.0.1",
"@size-limit/preset-big-lib": "12.0.0",
"@storybook/addon-a11y": "10.2.10",
From acac0760a8ff17babec6a4a36b54c361b805bc84 Mon Sep 17 00:00:00 2001
From: Troy Chaplin <15524465+troychaplin@users.noreply.github.com>
Date: Tue, 4 Aug 2026 09:14:08 -0400
Subject: [PATCH 2/2] remove button from listing
---
lib/components/Listing/Listing.stories.tsx | 77 ++++------------------
lib/components/Listing/ListingExcerpt.tsx | 2 +-
lib/components/Listing/ListingHeader.tsx | 7 +-
lib/components/Listing/styles.css | 5 ++
4 files changed, 23 insertions(+), 68 deletions(-)
diff --git a/lib/components/Listing/Listing.stories.tsx b/lib/components/Listing/Listing.stories.tsx
index fae6b66a6..3a1962954 100644
--- a/lib/components/Listing/Listing.stories.tsx
+++ b/lib/components/Listing/Listing.stories.tsx
@@ -30,13 +30,8 @@ export const Default: Story = {
-
+
-
-
- More info
-
-
@@ -54,13 +49,8 @@ export const SingleNewsListing: Story = {
-
+
-
-
- Read more
-
-
))}
@@ -80,13 +70,8 @@ export const MultipleNewsListings: Story = {
-
+
-
-
- Read more
-
-
))}
@@ -115,7 +100,7 @@ export const SingleEventListing: Story = {
-
+
-
-
- Event details
-
-
),
@@ -158,7 +138,7 @@ export const MultipleEventListings: Story = {
-
+
-
-
- Event details
-
-
),
@@ -190,13 +165,8 @@ export const SingleIconListing: Story = {
-
+
-
-
- Get informed
-
-
))}
@@ -214,13 +184,8 @@ export const MultipleIconListing: Story = {
-
+
-
-
- Get informed
-
-
))}
@@ -237,13 +202,8 @@ export const SinglePageListing: Story = {
{NewsData.slice(0, 1).map(({ id, link, title, date }) => (
-
+
-
-
- Read more
-
-
))}
@@ -260,13 +220,8 @@ export const MultiplePageListing: Story = {
{NewsData.slice(1, 5).map(({ id, link, title, date }) => (
-
+
-
-
- Read more
-
-
))}
@@ -286,15 +241,10 @@ export const SinglePeopleListing: Story = {
-
+
{email}
-
-
- View profile
-
-
))}
@@ -314,15 +264,10 @@ export const MultiplePeopleListing: Story = {
-
+
{email}
-
-
- View profile
-
-
))}
diff --git a/lib/components/Listing/ListingExcerpt.tsx b/lib/components/Listing/ListingExcerpt.tsx
index 47eb8f7c2..28c586b36 100644
--- a/lib/components/Listing/ListingExcerpt.tsx
+++ b/lib/components/Listing/ListingExcerpt.tsx
@@ -6,7 +6,7 @@ export interface ListingExcerptProps {
export const ListingExcerpt = ({ text, hasMore }: ListingExcerptProps) => {
return (
- {text && text.length > 200 ? `${text.substring(0, 200)}...` : text}
+ {text && text.length > 300 ? `${text.substring(0, 300)}...` : text}
{hasMore && More}
)
diff --git a/lib/components/Listing/ListingHeader.tsx b/lib/components/Listing/ListingHeader.tsx
index 684bd720d..a3744c3d3 100644
--- a/lib/components/Listing/ListingHeader.tsx
+++ b/lib/components/Listing/ListingHeader.tsx
@@ -1,5 +1,8 @@
+import { useLinkContext } from '../LinkProvider/useLinkContext'
+
export interface ListingHeaderProps {
title: string
+ link?: string
as?: 'h2' | 'h3'
date?: string | Date
datePrefix?: string
@@ -9,12 +12,14 @@ export interface ListingHeaderProps {
export const ListingHeader = ({
title = 'No title available',
+ link,
as = 'h2',
date,
datePrefix,
readTime,
datePosition = 'top',
}: ListingHeaderProps) => {
+ const LinkComponent = useLinkContext()
const HeaderComponent = as
const formattedDate = date
? new Date(date).toLocaleString('en-US', {
@@ -41,7 +46,7 @@ export const ListingHeader = ({
)}
- {title}
+ {link ? {title} : title}
{date && datePosition === 'bottom' && (
diff --git a/lib/components/Listing/styles.css b/lib/components/Listing/styles.css
index 6209daeb1..a859dea05 100644
--- a/lib/components/Listing/styles.css
+++ b/lib/components/Listing/styles.css
@@ -63,6 +63,11 @@
@apply inline-flex;
}
+.cu-listing header h2 a,
+.cu-listing header h3 a {
+ @apply block hover:text-cu-red-700;
+}
+
.cu-listing img:not(.cu-icon-thumb) {
@apply object-cover w-full h-full rounded-md;
}