mirror of
https://github.com/a2nt/cms-niceties.git
synced 2024-10-22 11:05:46 +02:00
[FIX] Assets Path
This commit is contained in:
parent
30ee3083b8
commit
25cdb138a8
@ -31,8 +31,8 @@ Dynamic\FlexSlider\Model\SlideImage:
|
||||
SilverStripe\Core\Injector\Injector:
|
||||
#SilverStripe\UserForms\Model\UserDefinedForm:
|
||||
# class: A2nt\CMSNiceties\Extensions\UserDefinedForm_HiddenClass
|
||||
#Sheadawson\Linkable\Forms\EmbeddedObjectField:
|
||||
# class: A2nt\CMSNiceties\Extensions\EmbedObjectField
|
||||
Sheadawson\Linkable\Forms\EmbeddedObjectField:
|
||||
class: A2nt\CMSNiceties\Extensions\EmbedObjectField
|
||||
SilverStripe\Forms\CompositeField:
|
||||
class: A2nt\CMSNiceties\Extensions\CompositeFieldExtension
|
||||
SilverStripe\Forms\GridField\GridFieldConfig_RecordEditor:
|
||||
|
@ -1,15 +1,14 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace A2nt\CMSNiceties\Extensions;
|
||||
|
||||
use gorriecoe\Embed\Extensions\Embeddable;
|
||||
use Sheadawson\Linkable\Forms\EmbeddedObjectField;
|
||||
use SilverStripe\Forms\CheckboxField;
|
||||
use SilverStripe\Forms\CompositeField;
|
||||
use SilverStripe\Forms\LiteralField;
|
||||
use SilverStripe\ORM\FieldType\DBHTMLText;
|
||||
|
||||
class EmbedObjectField extends Embeddable
|
||||
class EmbedObjectField extends EmbeddedObjectField
|
||||
{
|
||||
/**
|
||||
* List the allowed included embed types. If null all are allowed.
|
||||
@ -30,10 +29,9 @@ class EmbedObjectField extends Embeddable
|
||||
* @param array $properties
|
||||
* @return mixed|DBHTMLText
|
||||
*/
|
||||
/*public function FieldHolder($properties = [])
|
||||
public function FieldHolder($properties = [])
|
||||
{
|
||||
$name = $this->getName();
|
||||
|
||||
$fields = [
|
||||
CheckboxField::create(
|
||||
$name . '[autoplay]',
|
||||
@ -57,5 +55,5 @@ class EmbedObjectField extends Embeddable
|
||||
parent::FieldHolder($properties)
|
||||
)
|
||||
], $fields));
|
||||
}*/
|
||||
}
|
||||
}
|
||||
|
@ -97,6 +97,7 @@ class EmbeddedObjectExtension extends DataExtension
|
||||
|
||||
if ($this->owner->getField('Autoplay')) {
|
||||
$params[] = 'autoplay=1';
|
||||
$params[] = 'muted=1';
|
||||
}
|
||||
|
||||
if ($this->owner->getField('Loop')) {
|
||||
|
@ -137,7 +137,7 @@ class WebpackTemplateProvider implements TemplateGlobalProvider
|
||||
public static function toPublicPath($path): string
|
||||
{
|
||||
$cfg = self::config();
|
||||
if (strpos($path, '//')) {
|
||||
if (strpos($path, '//') || strpos($path, '/')) {
|
||||
return $path;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user