| @@ -1,15 +1,15 @@ | ||
| 1 | 1 | <?php |
| 2 | 2 | namespace Elementor; |
| 3 | 3 | |
| 4 | -use Elementor\Core\Utils\Promotions\Filtered_Promotions_Manager; | |
| 4 | +use Elementor\Core\Editor\Editor; | |
| 5 | 5 | |
| 6 | 6 | if ( ! defined( 'ABSPATH' ) ) { |
| 7 | 7 | exit; // Exit if accessed directly. |
| 8 | 8 | } |
| 9 | 9 | |
| 10 | -$show_editing_panel_sticky_promotion = ! Utils::has_pro(); | |
| 11 | -$editing_panel_sticky_promotion = $show_editing_panel_sticky_promotion ? Filtered_Promotions_Manager::get_editor_panel_sticky_promotion() : []; | |
| 10 | +$document = Plugin::$instance->documents->get( Plugin::$instance->editor->get_post_id() ); | |
| 11 | +$is_editor_v2_active = Plugin::$instance->experiments->is_feature_active( Editor::EDITOR_V2_EXPERIMENT_NAME ); | |
| 12 | 12 | ?> |
| 13 | 13 | <script type="text/template" id="tmpl-elementor-panel"> |
| 14 | 14 | <div id="elementor-panel-state-loading"> |
| 15 | 15 | <i class="eicon-loading eicon-animation-spin"></i> |
| @@ -15,16 +15,14 @@ | ||
| 15 | 15 | <i class="eicon-loading eicon-animation-spin"></i> |
| 16 | 16 | </div> |
| 17 | 17 | <header id="elementor-panel-header-wrapper"></header> |
| 18 | 18 | <main id="elementor-panel-content-wrapper"></main> |
| 19 | - <footer id="elementor-panel-footer" class="elementor-panel-footer-back-compat-wrapper" hidden></footer> | |
| 19 | + <footer id="elementor-panel-footer"> | |
| 20 | + <div class="elementor-panel-container"></div> | |
| 21 | + </footer> | |
| 20 | 22 | <div id="elementor-mode-switcher"></div> |
| 21 | 23 | </script> |
| 22 | 24 | |
| 23 | -<script type="text/template" id="tmpl-elementor-panel-footer-back-compat"> | |
| 24 | - <button type="button" class="elementor-panel-footer-back-compat-preview" tabindex="-1" hidden></button> | |
| 25 | -</script> | |
| 26 | - | |
| 27 | 25 | <script type="text/template" id="tmpl-elementor-panel-menu"> |
| 28 | 26 | <div id="elementor-panel-page-menu-content"></div> |
| 29 | 27 | <# if ( elementor.config.document.panel.needHelpUrl ) { #> |
| 30 | 28 | <div id="elementor-panel__editor__help"> |
| @@ -56,10 +54,10 @@ | ||
| 56 | 54 | |
| 57 | 55 | <script type="text/template" id="tmpl-elementor-exit-dialog"> |
| 58 | 56 | <div><?php echo esc_html__( 'Now you can choose where you want to go on the site from the following options', 'elementor' ); ?></div> |
| 59 | 57 | <div> |
| 60 | - <?php printf( | |
| 61 | - /* translators: 1: Opening HTML <a> tag, 2: closing HTML <a> tag. */ | |
| 58 | + <!-- translators: 1: Opening HTML <a> tag, 2: closing HTML <a> tag. --> | |
| 59 | + <?php echo sprintf( | |
| 62 | 60 | esc_html__( 'Any time you can change the settings in %1$sUser Preferences%2$s', 'elementor' ), |
| 63 | 61 | '<a id="user-preferences">', |
| 64 | 62 | '</a>' |
| 65 | 63 | ); ?> |
| @@ -67,21 +65,92 @@ | ||
| 67 | 65 | <select id="exit-to-preferences"></select> <!-- Adding options by JS --> |
| 68 | 66 | </script> |
| 69 | 67 | |
| 70 | 68 | <script type="text/template" id="tmpl-elementor-panel-header"> |
| 71 | - <button id="elementor-panel-header-menu-button" class="elementor-header-button" aria-label="<?php echo esc_attr__( 'Menu', 'elementor' ); ?>"> | |
| 72 | - <i class="elementor-icon eicon-menu-bar tooltip-target" aria-hidden="true" data-tooltip="<?php echo esc_attr__( 'Menu', 'elementor' ); ?>"></i> | |
| 69 | + <button id="elementor-panel-header-menu-button" class="elementor-header-button"> | |
| 70 | + <i class="elementor-icon eicon-menu-bar tooltip-target" aria-hidden="true" data-tooltip="<?php esc_attr_e( 'Menu', 'elementor' ); ?>"></i> | |
| 71 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Menu', 'elementor' ); ?></span> | |
| 73 | 72 | </button> |
| 74 | 73 | <h2 id="elementor-panel-header-title"></h2> |
| 75 | - <# const extraClass = $e.components.get( 'document/elements' ).utils.allowAddingWidgets() ? '' : 'elementor-visibility-hidden'; #> | |
| 76 | - <button id="elementor-panel-header-add-button" class="elementor-header-button {{{ extraClass }}}" aria-label="<?php echo esc_attr__( 'Widgets Panel', 'elementor' ); ?>"> | |
| 77 | - <i class="elementor-icon eicon-apps tooltip-target" aria-hidden="true" data-tooltip="<?php echo esc_attr__( 'Widgets Panel', 'elementor' ); ?>"></i> | |
| 74 | + <button id="elementor-panel-header-add-button" class="elementor-header-button"> | |
| 75 | + <i class="elementor-icon eicon-apps tooltip-target" aria-hidden="true" data-tooltip="<?php esc_attr_e( 'Widgets Panel', 'elementor' ); ?>"></i> | |
| 76 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Widgets Panel', 'elementor' ); ?></span> | |
| 78 | 77 | </button> |
| 79 | 78 | </script> |
| 80 | 79 | |
| 80 | +<script type="text/template" id="tmpl-elementor-panel-footer-content"> | |
| 81 | + <button id="elementor-panel-footer-settings" class="elementor-panel-footer-tool elementor-leave-open tooltip-target" data-tooltip="<?php esc_attr_e( 'Settings', 'elementor' ); ?>"> | |
| 82 | + <i class="eicon-cog" aria-hidden="true"></i> | |
| 83 | + <span class="elementor-screen-only"><?php printf( esc_html__( '%s Settings', 'elementor' ), esc_html( $document::get_title() ) ); ?></span> | |
| 84 | + </button> | |
| 85 | + <button id="elementor-panel-footer-navigator" class="elementor-panel-footer-tool tooltip-target" data-tooltip="<?php | |
| 86 | + echo $is_editor_v2_active | |
| 87 | + ? esc_attr__( 'Structure', 'elementor' ) | |
| 88 | + : esc_attr__( 'Navigator', 'elementor' ); | |
| 89 | + ?>"> | |
| 90 | + <i class="eicon-navigator" aria-hidden="true"></i> | |
| 91 | + <span class="elementor-screen-only"><?php | |
| 92 | + echo $is_editor_v2_active | |
| 93 | + ? esc_html__( 'Structure', 'elementor' ) | |
| 94 | + : esc_html__( 'Navigator', 'elementor' ); | |
| 95 | + ?></span> | |
| 96 | + </button> | |
| 97 | + <button id="elementor-panel-footer-history" class="elementor-panel-footer-tool elementor-leave-open tooltip-target" data-tooltip="<?php esc_attr_e( 'History', 'elementor' ); ?>"> | |
| 98 | + <i class="eicon-history" aria-hidden="true"></i> | |
| 99 | + <span class="elementor-screen-only"><?php echo esc_html__( 'History', 'elementor' ); ?></span> | |
| 100 | + </button> | |
| 101 | + <button id="elementor-panel-footer-responsive" class="elementor-panel-footer-tool elementor-toggle-state tooltip-target" data-tooltip="<?php esc_attr_e( 'Responsive Mode', 'elementor' ); ?>"> | |
| 102 | + <i class="eicon-device-responsive" aria-hidden="true"></i> | |
| 103 | + <span class="elementor-screen-only"> | |
| 104 | + <?php echo esc_html__( 'Responsive Mode', 'elementor' ); ?> | |
| 105 | + </span> | |
| 106 | + </button> | |
| 107 | + <button id="elementor-panel-footer-saver-preview" class="elementor-panel-footer-tool tooltip-target" data-tooltip="<?php esc_attr_e( 'Preview Changes', 'elementor' ); ?>"> | |
| 108 | + <span id="elementor-panel-footer-saver-preview-label"> | |
| 109 | + <i class="eicon-preview-medium" aria-hidden="true"></i> | |
| 110 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Preview Changes', 'elementor' ); ?></span> | |
| 111 | + </span> | |
| 112 | + </button> | |
| 113 | + <div id="elementor-panel-footer-saver-publish" class="elementor-panel-footer-tool"> | |
| 114 | + <button id="elementor-panel-saver-button-publish" class="elementor-button e-primary elementor-disabled"> | |
| 115 | + <span class="elementor-state-icon"> | |
| 116 | + <i class="eicon-loading eicon-animation-spin" aria-hidden="true"></i> | |
| 117 | + </span> | |
| 118 | + <span id="elementor-panel-saver-button-publish-label"> | |
| 119 | + <?php echo esc_html__( 'Publish', 'elementor' ); ?> | |
| 120 | + </span> | |
| 121 | + </button> | |
| 122 | + </div> | |
| 123 | + <div id="elementor-panel-footer-saver-options" class="elementor-panel-footer-tool elementor-toggle-state"> | |
| 124 | + <button id="elementor-panel-saver-button-save-options" class="elementor-button e-primary tooltip-target elementor-disabled" data-tooltip="<?php esc_attr_e( 'Save Options', 'elementor' ); ?>" data-tooltip-offset="7"> | |
| 125 | + <i class="eicon-chevron-right" aria-hidden="true"></i> | |
| 126 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Save Options', 'elementor' ); ?></span> | |
| 127 | + </button> | |
| 128 | + <div class="elementor-panel-footer-sub-menu-wrapper"> | |
| 129 | + <p class="elementor-last-edited-wrapper"> | |
| 130 | + <span class="elementor-state-icon"> | |
| 131 | + <i class="eicon-loading eicon-animation-spin" aria-hidden="true"></i> | |
| 132 | + </span> | |
| 133 | + <span class="elementor-last-edited"> | |
| 134 | + </span> | |
| 135 | + </p> | |
| 136 | + <div class="elementor-panel-footer-sub-menu"> | |
| 137 | + <div id="elementor-panel-footer-sub-menu-item-save-draft" class="elementor-panel-footer-sub-menu-item elementor-disabled"> | |
| 138 | + <i class="elementor-icon eicon-save" aria-hidden="true"></i> | |
| 139 | + <span class="elementor-title"><?php echo esc_html__( 'Save Draft', 'elementor' ); ?></span> | |
| 140 | + </div> | |
| 141 | + <div id="elementor-panel-footer-sub-menu-item-save-template" class="elementor-panel-footer-sub-menu-item"> | |
| 142 | + <i class="elementor-icon eicon-folder" aria-hidden="true"></i> | |
| 143 | + <span class="elementor-title"><?php echo esc_html__( 'Save as Template', 'elementor' ); ?></span> | |
| 144 | + </div> | |
| 145 | + </div> | |
| 146 | + </div> | |
| 147 | + </div> | |
| 148 | +</script> | |
| 149 | + | |
| 81 | 150 | <script type="text/template" id="tmpl-elementor-mode-switcher-content"> |
| 82 | - <label for="elementor-mode-switcher-preview-input" id="elementor-mode-switcher-preview" title="<?php echo esc_attr__( 'Hide Panel', 'elementor' ); ?>"> | |
| 83 | - <i class="eicon eicon-angle-left" aria-hidden="true" tabindex="0"></i> | |
| 151 | + <label for="elementor-mode-switcher-preview-input" id="elementor-mode-switcher-preview" title="<?php esc_attr_e( 'Hide Panel', 'elementor' ); ?>"> | |
| 152 | + <i class="eicon" aria-hidden="true" tabindex="0"></i> | |
| 84 | 153 | <span class="elementor-screen-only"><?php echo esc_html__( 'Hide Panel', 'elementor' ); ?></span> |
| 85 | 154 | </label> |
| 86 | 155 | <input id="elementor-mode-switcher-preview-input" type="checkbox"> |
| 87 | 156 | </script> |
| @@ -115,37 +184,12 @@ | ||
| 115 | 184 | <i class="eicon-help-o" aria-hidden="true"></i> |
| 116 | 185 | </a> |
| 117 | 186 | </div> |
| 118 | 187 | <# } #> |
| 119 | - | |
| 120 | - <# if ( elementData.upsale_data && elementData.upsale_data.condition ) { #> | |
| 121 | - <div class="elementor-nerd-box elementor-nerd-box--upsale"> | |
| 122 | - <# if ( elementData.upsale_data.image ) { #> | |
| 123 | - <img class="elementor-nerd-box-icon" src="{{ elementData.upsale_data.image }}" loading="lazy" alt="{{ elementData.upsale_data.image_alt }}" /> | |
| 124 | - <# } #> | |
| 125 | - <# if ( elementData.upsale_data.title ) { #> | |
| 126 | - <div class="elementor-nerd-box-title">{{{ elementData.upsale_data.title }}}</div> | |
| 127 | - <# } #> | |
| 128 | - <# if ( elementData.upsale_data.description ) { #> | |
| 129 | - <div class="elementor-nerd-box-message">{{{ elementData.upsale_data.description }}}</div> | |
| 130 | - <# } #> | |
| 131 | - <# if ( elementData.upsale_data.upgrade_url && elementData.upsale_data.upgrade_text ) { #> | |
| 132 | - <a class="elementor-button go-pro" href="{{ elementData.upsale_data.upgrade_url }}" target="_blank">{{{ elementData.upsale_data.upgrade_text }}}</a> | |
| 133 | - <# } #> | |
| 134 | - </div> | |
| 135 | - <# } #> | |
| 136 | - <?php if ( $show_editing_panel_sticky_promotion ) : ?> | |
| 137 | - <div class="elementor-panel-editor-sticky-promotion"> | |
| 138 | - <div class="elementor-get-pro-sticky-message"> | |
| 139 | - <?php echo esc_html( $editing_panel_sticky_promotion['message'] ); ?> | |
| 140 | - <a target="_blank" href="<?php echo esc_url( $editing_panel_sticky_promotion['url'] ); ?>"><?php echo esc_html( $editing_panel_sticky_promotion['button_text'] ); ?></a> | |
| 141 | - </div> | |
| 142 | - </div> | |
| 143 | - <?php endif; ?> | |
| 144 | 188 | </script> |
| 145 | 189 | |
| 146 | 190 | <script type="text/template" id="tmpl-elementor-panel-schemes-disabled"> |
| 147 | - <img class="elementor-nerd-box-icon" src="<?php Utils::print_unescaped_internal_string( ELEMENTOR_ASSETS_URL . 'images/information.svg' ); ?>" loading="lazy" alt="<?php echo esc_attr__( 'Elementor', 'elementor' ); ?>" /> | |
| 191 | + <img class="elementor-nerd-box-icon" src="<?php Utils::print_unescaped_internal_string( ELEMENTOR_ASSETS_URL . 'images/information.svg' ); ?>" loading="lazy" /> | |
| 148 | 192 | <div class="elementor-nerd-box-title">{{{ '<?php echo esc_html__( '%s are disabled', 'elementor' ); // phpcs:ignore WordPress.WP.I18n.MissingTranslatorsComment ?>'.replace( '%s', disabledTitle ) }}}</div> |
| 149 | 193 | <div class="elementor-nerd-box-message"><?php |
| 150 | 194 | printf( |
| 151 | 195 | /* translators: %1$s Link open tag, %2$s: Link close tag. */ |
| @@ -163,9 +207,9 @@ | ||
| 163 | 207 | |
| 164 | 208 | <script type="text/template" id="tmpl-elementor-panel-scheme-typography-item"> |
| 165 | 209 | <div class="elementor-panel-heading"> |
| 166 | 210 | <div class="elementor-panel-heading-toggle"> |
| 167 | - <i class="eicon-caret-right" aria-hidden="true"></i> | |
| 211 | + <i class="eicon" aria-hidden="true"></i> | |
| 168 | 212 | </div> |
| 169 | 213 | <div class="elementor-panel-heading-title">{{{ title }}}</div> |
| 170 | 214 | </div> |
| 171 | 215 | <div class="elementor-panel-scheme-typography-items elementor-panel-box-content"> |
| @@ -221,10 +265,11 @@ | ||
| 221 | 265 | // The 'Desktop' label is made accessible via the global config because it needs to be translated. |
| 222 | 266 | var deviceLabel = 'desktop' === device ? '<?php esc_html_e( 'Desktop', 'elementor' ); ?>' : activeBreakpoints[ device ].label, |
| 223 | 267 | tooltipDir = "<?php echo is_rtl() ? 'e' : 'w'; ?>"; |
| 224 | 268 | #> |
| 225 | - <button class="elementor-responsive-switcher tooltip-target elementor-responsive-switcher-{{ device }}" data-device="{{ device }}" data-tooltip="{{ deviceLabel }}" data-tooltip-pos="{{ tooltipDir }}" aria-label="{{ deviceLabel }}"> | |
| 269 | + <button class="elementor-responsive-switcher tooltip-target elementor-responsive-switcher-{{ device }}" data-device="{{ device }}" data-tooltip="{{ deviceLabel }}" data-tooltip-pos="{{ tooltipDir }}"> | |
| 226 | 270 | <i class="{{ elementor.config.responsive.icons_map[ device ] }}" aria-hidden="true"></i> |
| 271 | + <span class="elementor-screen-only">{{ deviceLabel }}</span> | |
| 227 | 272 | </button> |
| 228 | 273 | <# } ); |
| 229 | 274 | #> |
| 230 | 275 | </div> |
| @@ -231,17 +276,18 @@ | ||
| 231 | 276 | </div> |
| 232 | 277 | </script> |
| 233 | 278 | |
| 234 | 279 | <script type="text/template" id="tmpl-elementor-control-dynamic-switcher"> |
| 235 | - <button class="elementor-control-dynamic-switcher elementor-control-unit-1" data-tooltip="<?php echo esc_attr__( 'Dynamic Tags', 'elementor' ); ?>" aria-label="<?php echo esc_attr__( 'Dynamic Tags', 'elementor' ); ?>"> | |
| 280 | + <div class="elementor-control-dynamic-switcher elementor-control-unit-1" data-tooltip="<?php echo esc_attr__( 'Dynamic Tags', 'elementor' ); ?>"> | |
| 236 | 281 | <i class="eicon-database" aria-hidden="true"></i> |
| 237 | - </button> | |
| 282 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Dynamic Tags', 'elementor' ); ?></span> | |
| 283 | + </div> | |
| 238 | 284 | </script> |
| 239 | - | |
| 240 | 285 | <script type="text/template" id="tmpl-elementor-control-element-color-picker"> |
| 241 | - <button class="elementor-control-element-color-picker e-control-tool" data-tooltip="<?php echo esc_attr__( 'Color Sampler', 'elementor' ); ?>" aria-label="<?php echo esc_attr__( 'Color Sampler', 'elementor' ); ?>"> | |
| 286 | + <div class="elementor-control-element-color-picker e-control-tool" data-tooltip="<?php echo esc_attr__( 'Color Sampler', 'elementor' ); ?>"> | |
| 242 | 287 | <i class="eicon-eyedropper" aria-hidden="true"></i> |
| 243 | - </button> | |
| 288 | + <span class="elementor-screen-only"><?php echo esc_html__( 'Color Sampler', 'elementor' ); ?></span> | |
| 289 | + </div> | |
| 244 | 290 | </script> |
| 245 | 291 | |
| 246 | 292 | <script type="text/template" id="tmpl-elementor-control-dynamic-cover"> |
| 247 | 293 | <div class="elementor-dynamic-cover__settings"> |