fromObjectWithHtmlRestrictions example



  /** * Constructs a set of HTML restrictions matching the given text format. * * @param \Drupal\filter\Plugin\FilterInterface $filter * A filter plugin instance to construct a HTML restrictions object for. * * @return \Drupal\ckeditor5\HTMLRestrictions */
  public static function fromFilterPluginInstance(FilterInterface $filter): HTMLRestrictions {
    return self::fromObjectWithHtmlRestrictions($filter);
  }

  /** * Constructs a set of HTML restrictions matching the given text format. * * @param \Drupal\filter\FilterFormatInterface $text_format * A text format to construct a HTML restrictions object for. * * @return \Drupal\ckeditor5\HTMLRestrictions */
  public static function fromTextFormat(FilterFormatInterface $text_format): HTMLRestrictions {
    
Home | Imprint | This part of the site doesn't use cookies.