public function TableTagPlugin::getDefaultSample in Extensible BBCode 8.3
Same name and namespace in other branches
- 4.0.x standard/src/Plugin/XBBCode/TableTagPlugin.php \Drupal\xbbcode_standard\Plugin\XBBCode\TableTagPlugin::getDefaultSample()
Return the unprocessed sample code.
This should have {{ name }} placeholders for the tag name.
Return value
string The sample code.
Overrides TagPluginBase::getDefaultSample
File
- standard/
src/ Plugin/ XBBCode/ TableTagPlugin.php, line 87
Class
- TableTagPlugin
- Renders a table.
Namespace
Drupal\xbbcode_standard\Plugin\XBBCodeCode
public function getDefaultSample() : string {
// Generate the sample here, as annotations don't do well with linebreaks.
return $this
->t('[{{ name }} caption=Title header=!Item,Color,#Amount]
Fish,Red,1
Fish,Blue,2
[/{{ name }}]
[{{ name }}=~Left,Auto,!Center,#Right]
One,Two,Three,"Four, Five"
1,2,3,4
[/{{ name }}]
');
}