diff --git a/static/js/SearchSheetResult.jsx b/static/js/SearchSheetResult.jsx index b5061b2302..3de7ed4f45 100644 --- a/static/js/SearchSheetResult.jsx +++ b/static/js/SearchSheetResult.jsx @@ -30,9 +30,7 @@ class SearchSheetResult extends Component { } formatDate(dateString) { const date = new Date(dateString); - // Define options for Intl.DateTimeFormat const options = { year: 'numeric', month: 'long', day: 'numeric' }; - // Use Intl.DateTimeFormat to format the date return new Intl.DateTimeFormat('en-US', options).format(date); } render() { @@ -43,28 +41,28 @@ class SearchSheetResult extends Component { const snippetClasses = classNames({snippet: 1, en: snippetMarkup.lang === "en", he: snippetMarkup.lang === "he"}); const ownerIsHe = Sefaria.hebrew.isHebrew(s.owner_name); const titleIsHe = Sefaria.hebrew.isHebrew(clean_title); - const date = this.formatDate(this.props.metadata.dateCreated); + const dateString = this.formatDate(this.props.metadata.dateCreated); return (
- -
- - - {s.owner_name} - {'\u2022'} - - {date} +
+ + + {s.owner_name} + {'\u2022'} + + {dateString} - -
+ +
+
{clean_title}