__( 'SEO title', 'swiftling' ), '_seopress_titles_desc' => __( 'Meta description', 'swiftling' ), '_seopress_social_fb_title' => __( 'Facebook title', 'swiftling' ), '_seopress_social_fb_desc' => __( 'Facebook description', 'swiftling' ), '_seopress_social_twitter_title' => __( 'X title', 'swiftling' ), '_seopress_social_twitter_desc' => __( 'X description', 'swiftling' ), '_seopress_robots_breadcrumbs' => __( 'Breadcrumb title', 'swiftling' ), ); return null !== $key && isset( $labels[ $key ] ) ? $labels[ $key ] : ''; } /** * Returns the meta key of a value of a post or a term, as SEOPress keeps it: the whole value of * the key, not a part of it. * * @param string $owner Object key of the value. * @param string $path Path of the value inside its object. * @return string|null Null for a value of anything else. */ private static function metaKey( string $owner, string $path ): ?string { if ( 0 !== strpos( $owner, 'post:' ) && 0 !== strpos( $owner, 'term:' ) ) { return null; } if ( ! preg_match( '~^meta/(_seopress_[a-z_]+)$~', $path, $found ) ) { return null; } return $found[1]; } }