Skip to content

Commit ba08301

Browse files
authored
Merge branch 'main' into slars/tier-email-visibility
2 parents 7cd21bf + 16be8fb commit ba08301

113 files changed

Lines changed: 1447 additions & 714 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.secretlintrc.json

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,10 @@
4040
"name": "credential assignment",
4141
"patterns": [
4242
"/(?:^|[\\s{\"',])\\b(?:api[_-]?key|access[_-]?token|auth[_-]?token|client[_-]?secret|secret[_-]?key|private[_-]?key|password)\\b\\s*[:=]\\s*[\"']?(?<CREDENTIAL>[A-Za-z0-9_./+=:-]{20,})[\"']?/i"
43+
],
44+
"allows": [
45+
"/attempt-to-change-via-edit/",
46+
"/mynewfancypasswordwhichisnotallowed/"
4347
]
4448
},
4549
{

apps/posts/src/views/Automations/editor.tsx

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -450,9 +450,9 @@ const AutomationEditor: React.FC = () => {
450450
>
451451
<AlertDialogContent>
452452
<AlertDialogHeader>
453-
<AlertDialogTitle>Turn off this automation?</AlertDialogTitle>
453+
<AlertDialogTitle>Turn off automation?</AlertDialogTitle>
454454
<AlertDialogDescription>
455-
It will stop running until you turn it back on.
455+
Your automation will no longer run, and any members currently in progress will be removed.
456456
</AlertDialogDescription>
457457
</AlertDialogHeader>
458458
<AlertDialogFooter>
@@ -474,9 +474,9 @@ const AutomationEditor: React.FC = () => {
474474
>
475475
<AlertDialogContent>
476476
<AlertDialogHeader>
477-
<AlertDialogTitle>Update automation?</AlertDialogTitle>
477+
<AlertDialogTitle>Update your automation?</AlertDialogTitle>
478478
<AlertDialogDescription>
479-
This will update the automation for new runs of the automation, as well as any actively-running ones.
479+
Once published, your changes apply immediately to members already in progress and to any new members who enter the automation.
480480
</AlertDialogDescription>
481481
</AlertDialogHeader>
482482
<AlertDialogFooter>

apps/posts/src/views/comments/components/comment-header.tsx

Lines changed: 20 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import {Badge, Button, Tooltip, TooltipContent, TooltipProvider, TooltipTrigger, badgeVariants} from '@tryghost/shade/components';
1+
import {Badge, Button, Tooltip, TooltipContent, TooltipTrigger, badgeVariants} from '@tryghost/shade/components';
22
import {LucideIcon, cn, formatTimestamp} from '@tryghost/shade/utils';
33
import type {MouseEvent} from 'react';
44

@@ -73,34 +73,30 @@ export function CommentHeader({
7373
)}
7474
</div>
7575
{canComment === false && (
76-
<TooltipProvider>
76+
<Tooltip>
77+
<TooltipTrigger asChild>
78+
<span data-testid="commenting-disabled-indicator">
79+
<LucideIcon.MessageCircleOff
80+
className="size-3.5 text-muted-foreground"
81+
/>
82+
</span>
83+
</TooltipTrigger>
84+
<TooltipContent>Comments disabled</TooltipContent>
85+
</Tooltip>
86+
)}
87+
<LucideIcon.Dot className='shrink-0 text-muted-foreground/50' size={16} />
88+
<div className='shrink-0 whitespace-nowrap'>
89+
{createdAt && (
7790
<Tooltip>
7891
<TooltipTrigger asChild>
79-
<span data-testid="commenting-disabled-indicator">
80-
<LucideIcon.MessageCircleOff
81-
className="size-3.5 text-muted-foreground"
82-
/>
92+
<span className="cursor-default text-sm text-muted-foreground">
93+
{formatTimestamp(createdAt)}
8394
</span>
8495
</TooltipTrigger>
85-
<TooltipContent>Comments disabled</TooltipContent>
96+
<TooltipContent>
97+
{formatDate(createdAt)}
98+
</TooltipContent>
8699
</Tooltip>
87-
</TooltipProvider>
88-
)}
89-
<LucideIcon.Dot className='shrink-0 text-muted-foreground/50' size={16} />
90-
<div className='shrink-0 whitespace-nowrap'>
91-
{createdAt && (
92-
<TooltipProvider>
93-
<Tooltip>
94-
<TooltipTrigger asChild>
95-
<span className="cursor-default text-sm text-muted-foreground">
96-
{formatTimestamp(createdAt)}
97-
</span>
98-
</TooltipTrigger>
99-
<TooltipContent>
100-
{formatDate(createdAt)}
101-
</TooltipContent>
102-
</Tooltip>
103-
</TooltipProvider>
104100
)}
105101
</div>
106102
{postTitle && (

apps/posts/src/views/comments/components/comment-metrics.tsx

Lines changed: 34 additions & 36 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ import CommentReportsModal from './comment-reports-modal';
33
import {Comment} from '@tryghost/admin-x-framework/api/comments';
44
import {Link, useSearchParams} from '@tryghost/admin-x-framework';
55
import {LucideIcon, cn, formatNumber} from '@tryghost/shade/utils';
6-
import {Tooltip, TooltipContent, TooltipProvider, TooltipTrigger} from '@tryghost/shade/components';
6+
import {Tooltip, TooltipContent, TooltipTrigger} from '@tryghost/shade/components';
77
import {useState} from 'react';
88

99
interface MetricProps {
@@ -28,41 +28,39 @@ function Metric({icon, count, label, to, onClick, className, testId}: MetricProp
2828
const isClickable = to || onClick;
2929

3030
return (
31-
<TooltipProvider>
32-
<Tooltip>
33-
<TooltipTrigger asChild>
34-
{to ? (
35-
<Link
36-
className={cn(baseClassName, 'cursor-pointer hover:opacity-70')}
37-
data-testid={testId}
38-
to={to}
39-
onClick={(e: React.MouseEvent) => {
40-
e.stopPropagation();
41-
}}
42-
>
43-
{content}
44-
</Link>
45-
) : onClick ? (
46-
<button
47-
className={cn(baseClassName, 'cursor-pointer hover:opacity-70')}
48-
data-testid={testId}
49-
type="button"
50-
onClick={(e) => {
51-
e.stopPropagation();
52-
onClick();
53-
}}
54-
>
55-
{content}
56-
</button>
57-
) : (
58-
<div className={baseClassName} data-testid={testId}>
59-
{content}
60-
</div>
61-
)}
62-
</TooltipTrigger>
63-
<TooltipContent>{isClickable ? `View ${label.toLowerCase()}` : label}</TooltipContent>
64-
</Tooltip>
65-
</TooltipProvider>
31+
<Tooltip>
32+
<TooltipTrigger asChild>
33+
{to ? (
34+
<Link
35+
className={cn(baseClassName, 'cursor-pointer hover:opacity-70')}
36+
data-testid={testId}
37+
to={to}
38+
onClick={(e: React.MouseEvent) => {
39+
e.stopPropagation();
40+
}}
41+
>
42+
{content}
43+
</Link>
44+
) : onClick ? (
45+
<button
46+
className={cn(baseClassName, 'cursor-pointer hover:opacity-70')}
47+
data-testid={testId}
48+
type="button"
49+
onClick={(e) => {
50+
e.stopPropagation();
51+
onClick();
52+
}}
53+
>
54+
{content}
55+
</button>
56+
) : (
57+
<div className={baseClassName} data-testid={testId}>
58+
{content}
59+
</div>
60+
)}
61+
</TooltipTrigger>
62+
<TooltipContent>{isClickable ? `View ${label.toLowerCase()}` : label}</TooltipContent>
63+
</Tooltip>
6664
);
6765
}
6866

0 commit comments

Comments
 (0)