add nova
This commit is contained in:
19
nova/src/Fields/Markdown/DefaultPreset.php
Normal file
19
nova/src/Fields/Markdown/DefaultPreset.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
|
||||
namespace Laravel\Nova\Fields\Markdown;
|
||||
|
||||
use Illuminate\Support\Str;
|
||||
|
||||
class DefaultPreset implements MarkdownPreset
|
||||
{
|
||||
/**
|
||||
* Convert the given content from markdown to HTML.
|
||||
*
|
||||
* @param string $content
|
||||
* @return string
|
||||
*/
|
||||
public function convert(string $content)
|
||||
{
|
||||
return Str::markdown($content);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user