Skip to content

Commit a78a739

Browse files
committed
Rename props to be consistent with other HD prop names
1 parent 7237b82 commit a78a739

File tree

2 files changed

+11
-11
lines changed

2 files changed

+11
-11
lines changed

client/dashboard/components/empty-state/index.tsx

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,19 @@ import type { ReactNode } from 'react';
88

99
interface EmptyStateProps {
1010
buttons?: ReactNode;
11-
heading: string;
11+
description: string;
1212
illustration?: ReactNode;
13-
subHeading: string;
13+
title: string;
1414
}
1515

16-
export function EmptyState( { buttons, heading, illustration, subHeading }: EmptyStateProps ) {
16+
export function EmptyState( { buttons, title, illustration, description }: EmptyStateProps ) {
1717
return (
1818
<VStack spacing={ 6 } alignment="center" className="dashboard-empty-state">
1919
{ illustration }
2020
<VStack spacing={ 2 } alignment="center">
21-
<div className="dashboard-empty-state__heading">{ heading }</div>
21+
<div className="dashboard-empty-state__heading">{ title }</div>
2222
<Text variant="muted" align="center" className="dashboard-empty-state__sub-heading">
23-
{ subHeading }
23+
{ description }
2424
</Text>
2525
</VStack>
2626
{ buttons && (

client/dashboard/sites/index.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -107,19 +107,19 @@ export default function Sites() {
107107

108108
const hasFilterOrSearch = ( view.filters && view.filters.length > 0 ) || view.search;
109109

110-
const emptyHeading = hasFilterOrSearch ? __( 'No sites found' ) : __( 'No sites' );
110+
const emptyTitle = hasFilterOrSearch ? __( 'No sites found' ) : __( 'No sites' );
111111

112-
let emptySubHeading = __( 'Get started by creating a new site.' );
112+
let emptyDescription = __( 'Get started by creating a new site.' );
113113
if ( view.search ) {
114-
emptySubHeading = sprintf(
114+
emptyDescription = sprintf(
115115
// Translators: %s is the search term used when looking for sites by title or domain name.
116116
__(
117117
'Your search for “%s” did not match any sites. Try searching by the site title or domain name.'
118118
),
119119
view.search
120120
);
121121
} else if ( hasFilterOrSearch ) {
122-
emptySubHeading = __( 'Your search did not match any sites.' );
122+
emptyDescription = __( 'Your search did not match any sites.' );
123123
}
124124

125125
return (
@@ -160,8 +160,8 @@ export default function Sites() {
160160
perPageSizes={ DEFAULT_PER_PAGE_SIZES }
161161
empty={
162162
<EmptyState
163-
heading={ emptyHeading }
164-
subHeading={ emptySubHeading }
163+
title={ emptyTitle }
164+
description={ emptyDescription }
165165
illustration={
166166
<img src={ noSitesIllustration } alt="" width={ 408 } height={ 280 } />
167167
}

0 commit comments

Comments
 (0)