| 1 |
import React from 'react' |
| 2 |
import { __, sprintf } from '@wordpress/i18n' |
| 3 |
import { Badge } from '../../common/Badge' |
| 4 |
import { BLUEPRINT_TITLE } from './demoBlueprint' |
| 5 |
|
| 6 |
/** |
| 7 |
* Stands in for the code preview the real blueprint produces. The walkthrough |
| 8 |
* generates nothing, so this only confirms what Pro would have built. |
| 9 |
*/ |
| 10 |
export const GeneratedNotice = React.forwardRef<HTMLDivElement>((_props, ref) => |
| 11 |
<div className="blueprints-demo-generated" ref={ref} role="status"> |
| 12 |
<Badge name="php" /> |
| 13 |
|
| 14 |
<p className="blueprints-demo-generated__text"> |
| 15 |
{sprintf( |
| 16 |
/* translators: %s: name of the blueprint, e.g. "Create a Shortcode". */ |
| 17 |
__('Snippet ā%sā has been generated.', 'code-snippets'), |
| 18 |
BLUEPRINT_TITLE |
| 19 |
)} |
| 20 |
</p> |
| 21 |
</div>) |
| 22 |
|
| 23 |
GeneratedNotice.displayName = 'GeneratedNotice' |
| 24 |
|