PATH:
home
/
letacommog
/
puissancelec
/
wp-content
/
plugins
/
wordpress-seo
/
admin
<?php /** * WPSEO plugin file. * * @package WPSEO\Admin */ /** * Determines the location of an asset within the SEO plugin. */ final class WPSEO_Admin_Asset_SEO_Location implements WPSEO_Admin_Asset_Location { /** * @var string */ protected $plugin_file; /** * The plugin file to base the asset location upon. * * @param string $plugin_file The plugin file string. */ public function __construct( $plugin_file ) { $this->plugin_file = $plugin_file; } /** * Determines the URL of the asset on the dev server. * * @param WPSEO_Admin_Asset $asset The asset to determine the URL for. * @param string $type The type of asset. Usually JS or CSS. * * @return string The URL of the asset. */ public function get_url( WPSEO_Admin_Asset $asset, $type ) { $path = $this->get_path( $asset, $type ); if ( empty( $path ) ) { return ''; } if ( YOAST_ENVIRONMENT !== 'development' && ! $asset->get_suffix() ) { $plugin_path = plugin_dir_path( $this->plugin_file ); if ( ! file_exists( $plugin_path . $path ) ) { // Give a notice to the user in the console (only once). WPSEO_Utils::javascript_console_notification( 'Development Files', sprintf( /* translators: %1$s resolves to https://github.com/Yoast/wordpress-seo */ __( 'You are trying to load non-minified files. These are only available in our development package. Check out %1$s to see all the source files.', 'wordpress-seo' ), 'https://github.com/Yoast/wordpress-seo' ), true ); // Just load the .min file. $path = $this->get_path( $asset, $type, '.min' ); } } return plugins_url( $path, $this->plugin_file ); } /** * Determines the path relative to the plugin folder of an asset. * * @param WPSEO_Admin_Asset $asset The asset to determine the path * for. * @param string $type The type of asset. * @param string|null $force_suffix The suffix to force, or null when * to use the default suffix. * * @return string The path to the asset file. */ protected function get_path( WPSEO_Admin_Asset $asset, $type, $force_suffix = null ) { $relative_path = ''; $rtl_suffix = ''; $suffix = ( $force_suffix === null ) ? $asset->get_suffix() : $force_suffix; switch ( $type ) { case WPSEO_Admin_Asset::TYPE_JS: $relative_path = 'js/dist/' . $asset->get_src() . $suffix . '.js'; break; case WPSEO_Admin_Asset::TYPE_CSS: // Path and suffix for RTL stylesheets. if ( function_exists( 'is_rtl' ) && is_rtl() && $asset->has_rtl() ) { $rtl_suffix = '-rtl'; } $relative_path = 'css/dist/' . $asset->get_src() . $rtl_suffix . $suffix . '.css'; break; } return $relative_path; } }
[+]
..
[-] class-collector.php
[edit]
[-] class-yoast-alerts.php
[edit]
[-] class-option-tabs-formatter.php
[edit]
[-] class-meta-storage.php
[edit]
[-] class-admin-init.php
[edit]
[-] class-help-center.php
[edit]
[-] class-remote-request.php
[edit]
[-] class-recalculate-scores.php
[edit]
[+]
tracking
[-] class-bulk-editor-list-table.php
[edit]
[+]
filters
[-] class-admin-media-purge-notification.php
[edit]
[-] class-admin-utils.php
[edit]
[+]
config-ui
[-] class-bulk-title-editor-list-table.php
[edit]
[+]
views
[+]
statistics
[-] class-admin-asset-yoast-components-l10n.php
[edit]
[+]
notifiers
[+]
menu
[-] class-recalibration-beta.php
[edit]
[-] class-premium-popup.php
[edit]
[+]
roles
[-] class-meta-table-accessible.php
[edit]
[-] class-help-center-item.php
[edit]
[-] ajax.php
[edit]
[-] class-plugin-conflict.php
[edit]
[-] class-yoast-plugin-conflict.php
[edit]
[+]
exceptions
[+]
google_search_console
[+]
onpage
[-] class-admin.php
[edit]
[+]
taxonomy
[+]
ajax
[-] class-plugin-compatibility.php
[edit]
[-] class-admin-asset-analysis-worker-location.php
[edit]
[+]
help_center
[-] class-database-proxy.php
[edit]
[-] class-add-keyword-modal.php
[edit]
[+]
formatter
[+]
pages
[-] class-suggested-plugins.php
[edit]
[-] index.php
[edit]
[-] class-bulk-description-editor-list-table.php
[edit]
[-] class-option-tab.php
[edit]
[-] class-export.php
[edit]
[+]
capabilities
[-] class-customizer.php
[edit]
[-] interface-collection.php
[edit]
[+]
watchers
[-] class-yoast-network-settings-api.php
[edit]
[+]
endpoints
[-] class-license-page-manager.php
[edit]
[+]
metabox
[-] class-admin-gutenberg-compatibility-notification.php
[edit]
[-] class-plugin-availability.php
[edit]
[+]
recalculate
[-] class-admin-asset-location.php
[edit]
[-] class-gutenberg-compatibility.php
[edit]
[-] class-premium-upsell-admin-block.php
[edit]
[-] class-admin-asset-manager.php
[edit]
[-] class-primary-term-admin.php
[edit]
[+]
links
[-] class-social-admin.php
[edit]
[-] class-yoast-form.php
[edit]
[-] class-extensions.php
[edit]
[-] class-extension.php
[edit]
[-] class-meta-columns.php
[edit]
[-] class-extension-manager.php
[edit]
[-] class-yoast-network-admin.php
[edit]
[-] class-expose-shortlinks.php
[edit]
[-] class-admin-editor-specific-replace-vars.php
[edit]
[+]
listeners
[-] class-yoast-columns.php
[edit]
[-] class-option-tabs.php
[edit]
[-] class-config.php
[edit]
[-] class-keyword-synonyms-modal.php
[edit]
[-] class-admin-recommended-replace-vars.php
[edit]
[-] class-yoast-dashboard-widget.php
[edit]
[-] class-paper-presenter.php
[edit]
[-] class-admin-asset-dev-server-location.php
[edit]
[-] class-asset.php
[edit]
[-] class-yoast-notification.php
[edit]
[-] class-yoast-notification-center.php
[edit]
[-] class-admin-user-profile.php
[edit]
[-] class-admin-help-panel.php
[edit]
[-] class-admin-asset-seo-location.php
[edit]
[+]
import
[-] interface-installable.php
[edit]
[+]
services
[-] my-yoast-proxy.php
[edit]
[-] class-multiple-keywords-modal.php
[edit]
[-] class-product-upsell-notice.php
[edit]