Software: Apache/2.4.41 (Ubuntu). PHP/8.0.30 uname -a: Linux apirnd 5.4.0-204-generic #224-Ubuntu SMP Thu Dec 5 13:38:28 UTC 2024 x86_64 uid=33(www-data) gid=33(www-data) groups=33(www-data) Safe-mode: OFF (not secure) /var/www/html/wincloud_gateway/node_modules/strapi-admin/admin/src/containers/HomePage/ drwxr-xr-x | |
| Viewing file: Select action/file-type: import React, { memo } from 'react';
import PropTypes from 'prop-types';
import { LoadingBar } from 'strapi-helper-plugin';
const BlogPost = ({ error, isFirst, isLoading, title, content, link }) => {
if (isLoading) {
return (
<>
<LoadingBar style={{ marginBottom: 13 }} />
<LoadingBar style={{ width: '40%', marginBottom: 31 }} />
</>
);
}
if (error) {
return null;
}
return (
<a
rel="noopener noreferrer"
target="_blank"
href={`https://strapi.io/blog/${link}`}
style={{ color: '#333740' }}
>
<h2>{title}</h2>
<p style={{ marginTop: 17, marginBottom: isFirst ? 32 : 10 }}>{content}</p>
</a>
);
};
BlogPost.defaultProps = {
content: null,
isFirst: false,
link: null,
title: null,
};
BlogPost.propTypes = {
content: PropTypes.string,
error: PropTypes.bool.isRequired,
isFirst: PropTypes.bool,
isLoading: PropTypes.bool.isRequired,
link: PropTypes.string,
title: PropTypes.string,
};
export default memo(BlogPost);
|
:: Command execute :: | |
--[ c99shell v. 2.5 [PHP 8 Update] [24.05.2025] | Generation time: 0.0356 ]-- |