@@ -48,12 +48,12 @@ discard block |
||
| 48 | 48 | if (($pos = strpos($query, 'v=')) !== false) { |
| 49 | 49 | $videoId = substr($query, $pos + 2); |
| 50 | 50 | |
| 51 | - $url = $scheme . '://' . $host . '/embed/' . $videoId; |
|
| 51 | + $url = $scheme.'://'.$host.'/embed/'.$videoId; |
|
| 52 | 52 | |
| 53 | 53 | if ($this->getCfgValue('controls')) { |
| 54 | 54 | $url .= '?rel=0&controls=0&showinfo=0'; |
| 55 | 55 | } else { |
| 56 | - $url .= '?' . $this->getCfgValue('controls'); |
|
| 56 | + $url .= '?'.$this->getCfgValue('controls'); |
|
| 57 | 57 | } |
| 58 | 58 | } |
| 59 | 59 | return $url; |
@@ -64,7 +64,7 @@ discard block |
||
| 64 | 64 | $path = trim($path, '/'); |
| 65 | 65 | $url = ''; |
| 66 | 66 | if (is_numeric($path)) { |
| 67 | - $url = 'https://player.vimeo.com/video/' . $path . '?color=0c88dd&title=0&byline=0&portrait=0&badge=0'; |
|
| 67 | + $url = 'https://player.vimeo.com/video/'.$path.'?color=0c88dd&title=0&byline=0&portrait=0&badge=0'; |
|
| 68 | 68 | } |
| 69 | 69 | return $url; |
| 70 | 70 | } |
@@ -102,6 +102,6 @@ discard block |
||
| 102 | 102 | |
| 103 | 103 | public function twigAdmin() |
| 104 | 104 | { |
| 105 | - return '{% if extras.url is not empty %}<div style="margin:25px;width:300px"><div class="video-container"><iframe width="640" height="480" src="{{ extras.url }}" frameborder="0" allowfullscreen></iframe></div></div>{% else %}<span class="block__empty-text">' . Module::t('block_video_no_video') . '</span>{% endif %}'; |
|
| 105 | + return '{% if extras.url is not empty %}<div style="margin:25px;width:300px"><div class="video-container"><iframe width="640" height="480" src="{{ extras.url }}" frameborder="0" allowfullscreen></iframe></div></div>{% else %}<span class="block__empty-text">'.Module::t('block_video_no_video').'</span>{% endif %}'; |
|
| 106 | 106 | } |
| 107 | 107 | } |
@@ -41,6 +41,6 @@ |
||
| 41 | 41 | |
| 42 | 42 | public function twigAdmin() |
| 43 | 43 | { |
| 44 | - return '{% if vars.content is empty %}<span class="block__empty-text">' . Module::t('block_wysiwyg_no_content') . '</span>{% else %}{{ vars.content }}{% endif %}'; |
|
| 44 | + return '{% if vars.content is empty %}<span class="block__empty-text">'.Module::t('block_wysiwyg_no_content').'</span>{% else %}{{ vars.content }}{% endif %}'; |
|
| 45 | 45 | } |
| 46 | 46 | } |
@@ -36,6 +36,6 @@ |
||
| 36 | 36 | |
| 37 | 37 | public function twigAdmin() |
| 38 | 38 | { |
| 39 | - return '{% if vars.content is not empty %}<blockquote>{{ vars.content }}</blockquote>{% else %}<span class="block__empty-text">' . Module::t('block_quote_no_content') . '</span>{% endif %}'; |
|
| 39 | + return '{% if vars.content is not empty %}<blockquote>{{ vars.content }}</blockquote>{% else %}<span class="block__empty-text">'.Module::t('block_quote_no_content').'</span>{% endif %}'; |
|
| 40 | 40 | } |
| 41 | 41 | } |
@@ -39,6 +39,6 @@ |
||
| 39 | 39 | |
| 40 | 40 | public function twigAdmin() |
| 41 | 41 | { |
| 42 | - return '{% if vars.html is empty %}<span class="block__empty-text">' . Module::t('block_html_no_content') . '</span>{% else %}{{ vars.html | raw }}{% endif %}'; |
|
| 42 | + return '{% if vars.html is empty %}<span class="block__empty-text">'.Module::t('block_html_no_content').'</span>{% else %}{{ vars.html | raw }}{% endif %}'; |
|
| 43 | 43 | } |
| 44 | 44 | } |
@@ -53,20 +53,20 @@ discard block |
||
| 53 | 53 | 'cfgs' => [ |
| 54 | 54 | ['var' => 'heading', 'label' => Module::t('block_image_text_heading_label'), 'type' => 'zaa-text'], |
| 55 | 55 | ['var' => 'headingType', 'label' => Module::t('block_image_text_headingtype_label'), 'type' => 'zaa-select', 'initvalue' => 'h3', 'options' => [ |
| 56 | - ['value' => 'h1', 'label' => Module::t('block_image_text_heading_label') . ' 1'], |
|
| 57 | - ['value' => 'h2', 'label' => Module::t('block_image_text_heading_label') . ' 2'], |
|
| 58 | - ['value' => 'h3', 'label' => Module::t('block_image_text_heading_label') . ' 3'], |
|
| 59 | - ['value' => 'h4', 'label' => Module::t('block_image_text_heading_label') . ' 4'], |
|
| 60 | - ['value' => 'h5', 'label' => Module::t('block_image_text_heading_label') . ' 5'], |
|
| 56 | + ['value' => 'h1', 'label' => Module::t('block_image_text_heading_label').' 1'], |
|
| 57 | + ['value' => 'h2', 'label' => Module::t('block_image_text_heading_label').' 2'], |
|
| 58 | + ['value' => 'h3', 'label' => Module::t('block_image_text_heading_label').' 3'], |
|
| 59 | + ['value' => 'h4', 'label' => Module::t('block_image_text_heading_label').' 4'], |
|
| 60 | + ['value' => 'h5', 'label' => Module::t('block_image_text_heading_label').' 5'], |
|
| 61 | 61 | ], |
| 62 | 62 | ], |
| 63 | 63 | ['var' => 'margin', 'label' => Module::t('block_image_text_margin_label'), 'type' => 'zaa-select', 'initvalue' => $this->defaultMargin, 'options' => [ |
| 64 | - ['value' => '5px', 'label' => '0 ' . Module::t('block_image_text_margin_pixel')], |
|
| 65 | - ['value' => '10px', 'label' => '10 ' . Module::t('block_image_text_margin_pixel')], |
|
| 66 | - ['value' => '15px', 'label' => '20 ' . Module::t('block_image_text_margin_pixel')], |
|
| 67 | - ['value' => '15px', 'label' => '30 ' . Module::t('block_image_text_margin_pixel')], |
|
| 68 | - ['value' => '15px', 'label' => '40 ' . Module::t('block_image_text_margin_pixel')], |
|
| 69 | - ['value' => '15px', 'label' => '50 ' . Module::t('block_image_text_margin_pixel')], |
|
| 64 | + ['value' => '5px', 'label' => '0 '.Module::t('block_image_text_margin_pixel')], |
|
| 65 | + ['value' => '10px', 'label' => '10 '.Module::t('block_image_text_margin_pixel')], |
|
| 66 | + ['value' => '15px', 'label' => '20 '.Module::t('block_image_text_margin_pixel')], |
|
| 67 | + ['value' => '15px', 'label' => '30 '.Module::t('block_image_text_margin_pixel')], |
|
| 68 | + ['value' => '15px', 'label' => '40 '.Module::t('block_image_text_margin_pixel')], |
|
| 69 | + ['value' => '15px', 'label' => '50 '.Module::t('block_image_text_margin_pixel')], |
|
| 70 | 70 | ], |
| 71 | 71 | ], |
| 72 | 72 | ['var' => 'textType', 'label' => Module::t('block_image_text_texttype_label'), 'initvalue' => 0, 'type' => 'zaa-select', 'options' => [ |
@@ -133,10 +133,10 @@ discard block |
||
| 133 | 133 | public function twigAdmin() |
| 134 | 134 | { |
| 135 | 135 | return '{% if not extras.imageAdmin.source %}'. |
| 136 | - '<span class="block__empty-text">' . Module::t('block_image_text_no_image') . '</span>'. |
|
| 136 | + '<span class="block__empty-text">'.Module::t('block_image_text_no_image').'</span>'. |
|
| 137 | 137 | '{% endif %}'. |
| 138 | 138 | '{% if not vars.text %}'. |
| 139 | - '<span class="block__empty-text">' . Module::t('block_image_text_no_text') . '</span>'. |
|
| 139 | + '<span class="block__empty-text">'.Module::t('block_image_text_no_text').'</span>'. |
|
| 140 | 140 | '{% endif %}'. |
| 141 | 141 | '{% if extras.imageAdmin.source and vars.text %}'. |
| 142 | 142 | '<img src="{{ extras.imageAdmin.source }}"{% if cfgs.width %} width="{{cfgs.width}}"{% endif %}{% if cfgs.height %} height="{{cfgs.height}}"{% endif %} border="0" style="{% if extras.imagePosition == "left" %}float:left;{% else %}float:right{% endif %};{% if extras.imagePosition == "right" %}margin-left:{{ extras.margin }}{% else %}margin-right:{{ extras.margin }}{% endif %};margin-bottom:{{ extras.margin }}; max-width: 50%;"">'. |
@@ -68,7 +68,7 @@ discard block |
||
| 68 | 68 | |
| 69 | 69 | public function twigAdmin() |
| 70 | 70 | { |
| 71 | - return '{% if vars.moduleName is empty %}<span class="block__empty-text">' . Module::t('block_module_no_module') . '</span>{% else %}<p><i class="material-icons">developer_board</i> ' . Module::t('block_module_integration') . ': <strong>{{ vars.moduleName }}</strong></p>{% endif %}'; |
|
| 71 | + return '{% if vars.moduleName is empty %}<span class="block__empty-text">'.Module::t('block_module_no_module').'</span>{% else %}<p><i class="material-icons">developer_board</i> '.Module::t('block_module_integration').': <strong>{{ vars.moduleName }}</strong></p>{% endif %}'; |
|
| 72 | 72 | } |
| 73 | 73 | |
| 74 | 74 | public function twigFrontend() |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | |
| 113 | 113 | return $response; |
| 114 | 114 | } catch (\Exception $err) { |
| 115 | - throw new Exception('Module Block Exception: ' . $err->getMessage()); |
|
| 115 | + throw new Exception('Module Block Exception: '.$err->getMessage()); |
|
| 116 | 116 | } |
| 117 | 117 | } |
| 118 | 118 | } |
@@ -101,7 +101,7 @@ |
||
| 101 | 101 | |
| 102 | 102 | public function twigAdmin() |
| 103 | 103 | { |
| 104 | - return '<p>{% if extras.table is empty %}<span class="block__empty-text">' . Module::t('block_table_no_table') . '</span>{% else %}'. |
|
| 104 | + return '<p>{% if extras.table is empty %}<span class="block__empty-text">'.Module::t('block_table_no_table').'</span>{% else %}'. |
|
| 105 | 105 | '<table>'. |
| 106 | 106 | '{% if cfgs.header %}'. |
| 107 | 107 | '<thead>'. |
@@ -72,7 +72,7 @@ |
||
| 72 | 72 | |
| 73 | 73 | public function twigAdmin() |
| 74 | 74 | { |
| 75 | - return '<p>{% if vars.content is empty %}<span class="block__empty-text">' . Module::t('block_text_no_content') . '</span>'. |
|
| 75 | + return '<p>{% if vars.content is empty %}<span class="block__empty-text">'.Module::t('block_text_no_content').'</span>'. |
|
| 76 | 76 | '{% elseif vars.content is not empty and vars.textType == 1 %}{{ extras.text }}{% elseif vars.content is not empty %}{{ extras.text|nl2br }}{% endif %}</p>'; |
| 77 | 77 | } |
| 78 | 78 | } |
@@ -26,11 +26,11 @@ discard block |
||
| 26 | 26 | 'vars' => [ |
| 27 | 27 | ['var' => 'content', 'label' => Module::t('block_title_content_label'), 'type' => 'zaa-text'], |
| 28 | 28 | ['var' => 'headingType', 'label' => Module::t('block_title_headingtype_label'), 'type' => 'zaa-select', 'initvalue' => 'h1', 'options' => [ |
| 29 | - ['value' => 'h1', 'label' => Module::t('block_title_headingtype_heading') . ' 1'], |
|
| 30 | - ['value' => 'h2', 'label' => Module::t('block_title_headingtype_heading') . ' 2'], |
|
| 31 | - ['value' => 'h3', 'label' => Module::t('block_title_headingtype_heading') . ' 3'], |
|
| 32 | - ['value' => 'h4', 'label' => Module::t('block_title_headingtype_heading') . ' 4'], |
|
| 33 | - ['value' => 'h5', 'label' => Module::t('block_title_headingtype_heading') . ' 5'], |
|
| 29 | + ['value' => 'h1', 'label' => Module::t('block_title_headingtype_heading').' 1'], |
|
| 30 | + ['value' => 'h2', 'label' => Module::t('block_title_headingtype_heading').' 2'], |
|
| 31 | + ['value' => 'h3', 'label' => Module::t('block_title_headingtype_heading').' 3'], |
|
| 32 | + ['value' => 'h4', 'label' => Module::t('block_title_headingtype_heading').' 4'], |
|
| 33 | + ['value' => 'h5', 'label' => Module::t('block_title_headingtype_heading').' 5'], |
|
| 34 | 34 | ], |
| 35 | 35 | ], |
| 36 | 36 | ], |
@@ -51,6 +51,6 @@ discard block |
||
| 51 | 51 | |
| 52 | 52 | public function twigAdmin() |
| 53 | 53 | { |
| 54 | - return '{% if vars.content is not empty %}<{{extras.headingType}}>{{ vars.content }}</{{extras.headingType}}>{% else %}<span class="block__empty-text">' . Module::t('block_title_no_content') . '</span>{% endif %}'; |
|
| 54 | + return '{% if vars.content is not empty %}<{{extras.headingType}}>{{ vars.content }}</{{extras.headingType}}>{% else %}<span class="block__empty-text">'.Module::t('block_title_no_content').'</span>{% endif %}'; |
|
| 55 | 55 | } |
| 56 | 56 | } |