| 1 | <?php |
||
| 29 | final class AssetAudio extends AssetsAbstract implements AssetAudioInterface |
||
| 30 | { |
||
| 31 | |||
| 32 | /** |
||
| 33 | * Autoplay audio |
||
| 34 | * |
||
| 35 | * @var bool |
||
| 36 | */ |
||
| 37 | protected $attr_autoplay; |
||
| 38 | |||
| 39 | /** |
||
| 40 | * Preload audio |
||
| 41 | * |
||
| 42 | * @var string |
||
| 43 | */ |
||
| 44 | protected $attr_preload; |
||
| 45 | |||
| 46 | /** |
||
| 47 | * Asset constructor set asset ID |
||
| 48 | * |
||
| 49 | * @param string $id |
||
| 50 | */ |
||
| 51 | 4 | public function __construct(string $id) |
|
| 56 | |||
| 57 | /** |
||
| 58 | * Autoplay audio |
||
| 59 | * |
||
| 60 | * @param bool $autoplay |
||
| 61 | * @return AssetAudioInterface |
||
| 62 | */ |
||
| 63 | 1 | public function autoplay(bool $autoplay = true): AssetAudioInterface |
|
| 68 | |||
| 69 | /** |
||
| 70 | * Preload audio |
||
| 71 | * |
||
| 72 | * @param string $preload |
||
| 73 | * @return AssetAudioInterface |
||
| 74 | */ |
||
| 75 | 1 | public function preload(string $preload = 'auto'): AssetAudioInterface |
|
| 80 | } |
||
| 81 |