19declare(strict_types=1);
66 protected string $resource_version,
67 protected bool $append_resource_version =
true,
68 protected bool $strip_queries =
false,
69 protected bool $allow_external =
true,
70 protected bool $allow_non_existing =
false,
74 $this->version_parameter_filters[] = $filter;
81 $this->version_parameter_filters[] = $filter;
82 $this->css->addVersionParameterFilter($filter);
83 $this->js->addVersionParameterFilter($filter);
89 $this->resource_version,
90 $this->append_resource_version,
92 $this->allow_external,
93 $this->allow_non_existing,
94 $this->version_parameter_filters
97 $this->resource_version,
98 $this->append_resource_version,
100 $this->allow_external,
101 $this->allow_non_existing,
102 $this->version_parameter_filters
105 $this->resource_version,
112 $this->resource_version,
118 $this->og_meta_data =
null;
119 $this->meta_data = [];
122 public function addCss(
string $path,
string $media = self::MEDIA_SCREEN): void
124 $this->css->addItem(
new Css(
$path, $this->resource_version, $media));
127 public function addJs(
string $path,
bool $add_version_number =
false,
int $batch = 2): void
129 $this->js->addItem(
new Js(
$path, $this->resource_version, $add_version_number, $batch));
132 public function addInlineCss(
string $content,
string $media = self::MEDIA_SCREEN): void
134 $this->inline_css->addItem(
new InlineCss($content, $this->resource_version, $media));
139 $this->on_load_code->addItem(
new OnLoadCode($content, $this->resource_version, $batch));
150 throw new \LogicException(
152 'Please use %s::addOpenGraphMetaDatum to add open-graph metadata.',
218 throw new \InvalidArgumentException(
'$text_direction MUST be Standard::LTR, or Standard::RTL');
addVersionParameterFilter(VersionParameterFilter $filter)
TagCollection $og_meta_data
addOpenGraphMetaDatum(TagCollection $og_meta_data)
__construct(protected string $resource_version, protected bool $append_resource_version=true, protected bool $strip_queries=false, protected bool $allow_external=true, protected bool $allow_non_existing=false, array $version_parameter_filters=[],)
addJs(string $path, bool $add_version_number=false, int $batch=2)
array $version_parameter_filters
setTextDirection(string $text_direction)
setBaseURL(string $base_url)
addOnloadCode(string $content, int $batch=2)
addMetaDatum(Tag $meta_data)
addCss(string $path, string $media=self::MEDIA_SCREEN)
OnLoadCodeCollection $on_load_code
addInlineCss(string $content, string $media=self::MEDIA_SCREEN)
InlineCssCollection $inline_css
Decides whether the resource version parameter (see {.