[629] Use Client Name as anchor text for targeted link#128
Conversation
📝 Walkthrough## Walkthrough
The changes update the styling of case study components and modify the template to conditionally render the case study title as a link to the client website if available. Link styles are consolidated, and external link security attributes are improved.
## Changes
| File(s) | Change Summary |
|-----------------------------------------------------------------------|----------------------------------------------------------------------------------------------------|
| website/modules/asset/ui/src/scss/_cases.scss | Adjusted placeholder image sizing, updated `.cs_details-page` and `.cs_full-details-card` `.cname a` link styles, removed `.client-website-link` class, consolidated link styles under `.prod-link`. |
| website/modules/case-studies-page/views/show.html | Case study title is now conditionally a link to the client website; added security attributes (`target="_blank"`, `rel="noopener noreferrer"`) to external links. |
## Sequence Diagram(s)
```mermaid
sequenceDiagram
participant User
participant CaseStudyPage
User->>CaseStudyPage: Visit case study page
CaseStudyPage->>CaseStudyPage: Check if clientWebsite exists
alt clientWebsite exists
CaseStudyPage->>User: Render title as link to client website
else clientWebsite missing
CaseStudyPage->>User: Render title as plain text
endPossibly related PRs
Suggested reviewers
|
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (2)
website/modules/asset/ui/src/scss/_cases.scss (1)
549-558: Consolidate link styles and add focus state for.cname aGood addition of default gray color and underline-on-hover for client name links. For maintainability and accessibility, consider:
- Extracting these common link styles into a shared mixin (similar to
.prod-link).- Adding a visible focus outline (e.g.,
outline: 2px solid $focus-color) to support keyboard navigation.website/modules/case-studies-page/views/show.html (1)
68-72: Improve anchor text for externalprodLinkAdding
rel="noopener noreferrer"is great for security. However, displaying the raw URL as link text can be verbose. Consider using more descriptive anchor text—like"View Live Site"or the client’s name—to enhance readability, SEO, and overall UX.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (2)
website/modules/asset/ui/src/scss/_cases.scss(3 hunks)website/modules/case-studies-page/views/show.html(2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (4)
- GitHub Check: e2e-tests
- GitHub Check: lint
- GitHub Check: unit-tests
- GitHub Check: security-scan
🔇 Additional comments (1)
website/modules/asset/ui/src/scss/_cases.scss (1)
362-364: Approve layout adjustments for placeholder containerThe switch from a fixed height to
max-height: 240pxwithheight: 100%, plus the increased top padding at large breakpoints, aligns the placeholder container size with the updated image dimensions. Ensure you test across breakpoints to confirm there are no overflow or alignment issues.Also applies to: 372-372
|



This PR implements the use of client names as anchor text for targeted links.