From a224d4b082c9b2f16e0f713cbdc3fb4087d30323 Mon Sep 17 00:00:00 2001
From: "Soare Robert Daniel (Mac 2023)"
Date: Fri, 29 Nov 2024 13:20:38 +0200
Subject: [PATCH 1/3] fix: add missing translatable strings
---
.../apps/customizer-controls/src/controls.js | 9 +-
.../src/customizer-search/SearchResults.tsx | 11 +-
.../src/Components/Content/Changelog.js | 4 +-
.../dashboard/src/Components/Notification.js | 11 +-
.../Core/Builder/Abstract_Builder.php | 10 +-
header-footer-grid/Core/Builder/Header.php | 16 +-
.../Core/Components/MenuIcon.php | 14 +-
.../components/component-footer-sidebar.php | 1 -
.../starter-content/theme-mods.php | 264 +++++++++---------
phpcs.xml | 39 +--
10 files changed, 199 insertions(+), 180 deletions(-)
diff --git a/assets/apps/customizer-controls/src/controls.js b/assets/apps/customizer-controls/src/controls.js
index 19632184f0..bf70546b41 100644
--- a/assets/apps/customizer-controls/src/controls.js
+++ b/assets/apps/customizer-controls/src/controls.js
@@ -1,6 +1,7 @@
/* global CustomEvent, NeveReactCustomize, MutationObserver */
import './public-path.js';
import { render } from '@wordpress/element';
+import { __ } from '@wordpress/i18n';
import { init as initDynamicFields } from './dynamic-fields/index';
import { ToggleControl } from './toggle/Control';
@@ -297,8 +298,10 @@ const checkHasElementorTemplates = () => {
'neve-custom-elementor-shop-template',
{
type: 'warning',
- message:
+ message: __(
'Some of the settings might not work as expected because you are using a custom shop template made in Elementor.',
+ 'neve'
+ ),
}
)
);
@@ -312,8 +315,10 @@ const checkHasElementorTemplates = () => {
'neve-custom-elementor-product-template',
{
type: 'warning',
- message:
+ message: __(
'Some of the settings might not work as expected because you are using a custom product template made in Elementor.',
+ 'neve'
+ ),
}
)
);
diff --git a/assets/apps/customizer-controls/src/customizer-search/SearchResults.tsx b/assets/apps/customizer-controls/src/customizer-search/SearchResults.tsx
index dc2fdde6d0..5f6defe9f3 100644
--- a/assets/apps/customizer-controls/src/customizer-search/SearchResults.tsx
+++ b/assets/apps/customizer-controls/src/customizer-search/SearchResults.tsx
@@ -1,6 +1,7 @@
import React from 'react';
import { Control } from './SearchComponent';
import classnames from 'classnames';
+import { __ } from '@wordpress/i18n';
/**
* Type SearchComponentProps
@@ -84,7 +85,9 @@ const SearchResults: React.FC = ({
{query !== '' && (
{matchResults.map((control) => {
- if ('' === control.label) return '';
+ if ('' === control.label) {
+ return '';
+ }
let breadcrumbs = control.panelName;
if (breadcrumbs === null) {
@@ -118,8 +121,10 @@ const SearchResults: React.FC = ({
>
{getHighlightedText(label, query)}
- Press return or enter to open this
- section
+ {__(
+ 'Press return or enter to open this section',
+ 'neve'
+ )}
diff --git a/assets/apps/dashboard/src/Components/Content/Changelog.js b/assets/apps/dashboard/src/Components/Content/Changelog.js
index 98548d7cd7..e5846395ea 100644
--- a/assets/apps/dashboard/src/Components/Content/Changelog.js
+++ b/assets/apps/dashboard/src/Components/Content/Changelog.js
@@ -21,7 +21,7 @@ const Changelog = () => {
setShowForPro(false);
}}
>
- Neve
+ {__('Neve', 'neve')}
{
setShowForPro(true);
}}
>
- Neve Pro
+ {__('Neve Pro', 'neve')}
)}
diff --git a/assets/apps/dashboard/src/Components/Notification.js b/assets/apps/dashboard/src/Components/Notification.js
index ef775e4548..b8cf8a94b4 100644
--- a/assets/apps/dashboard/src/Components/Notification.js
+++ b/assets/apps/dashboard/src/Components/Notification.js
@@ -143,9 +143,14 @@ const Notification = ({ data, slug }) => {
const wrappedButtonContent = !canInstallPlugins ? (
{
{errorMessage ||
__(
- 'An error occured. Please reload the page and try again.',
+ 'An error occurred. Please reload the page and try again.',
'neve'
)}
diff --git a/header-footer-grid/Core/Builder/Abstract_Builder.php b/header-footer-grid/Core/Builder/Abstract_Builder.php
index 1379c2e27f..0ab6c78907 100644
--- a/header-footer-grid/Core/Builder/Abstract_Builder.php
+++ b/header-footer-grid/Core/Builder/Abstract_Builder.php
@@ -167,10 +167,7 @@ abstract class Abstract_Builder implements Builder {
* @access protected
* @var array $devices
*/
- protected $devices = [
- 'desktop' => 'Desktop',
- 'mobile' => 'Mobile',
- ];
+ protected $devices = [];
/**
* Default colors for rows.
@@ -243,6 +240,11 @@ public function __construct() {
add_filter( 'hfg_header_row_classes', [ $this, 'add_header_row_utility_classes' ], 10, 2 );
add_filter( 'hfg_page_header_row_classes', [ $this, 'add_header_row_utility_classes' ], 10, 2 );
+
+ $this->devices = [
+ 'desktop' => __( 'Desktop', 'neve' ),
+ 'mobile' => __( 'Mobile', 'neve' ),
+ ];
}
/**
diff --git a/header-footer-grid/Core/Builder/Header.php b/header-footer-grid/Core/Builder/Header.php
index fb26e2834c..cfd1a21a0c 100644
--- a/header-footer-grid/Core/Builder/Header.php
+++ b/header-footer-grid/Core/Builder/Header.php
@@ -498,37 +498,37 @@ protected function get_rows() {
private function get_header_presets() {
$presets = [
[
- 'label' => 'Classic',
+ 'label' => __( 'Classic', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/Classic.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"primary-menu\"},{\"id\":\"header_search_responsive\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"nav-icon\"},{\"id\":\"header_search_responsive\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}"}',
],
[
- 'label' => 'Inverted',
- 'image' => NEVE_ASSETS_URL . 'img/header-presets/Inverted.jpg',
+ 'label' => __( 'Inverted', 'neve' ),
+ 'image' => NEVE_ASSETS_URL . 'img/header-presets/Inverted.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"primary-menu\"},{\"id\":\"header_search_responsive\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"logo\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"nav-icon\"},{\"id\":\"header_search_responsive\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"logo\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}","logo_component_align":{"mobile":"right","tablet":"right","desktop":"right"}}',
],
[
- 'label' => 'Centered',
+ 'label' => __( 'Centered', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/Centered.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[],\"c-left\":[],\"center\":[{\"id\":\"logo\"}],\"c-right\":[],\"right\":[]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[{\"id\":\"primary-menu\"}],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[],\"c-left\":[],\"center\":[{\"id\":\"logo\"}],\"c-right\":[],\"right\":[]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[{\"id\":\"nav-icon\"}],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}","logo_component_align":{"mobile":"center","tablet":"center","desktop":"center"}}',
],
[
- 'label' => 'Spaced',
+ 'label' => __( 'Spaced', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/Spaced.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"header_search_responsive\"}],\"c-left\":[],\"center\":[{\"id\":\"logo\"}],\"c-right\":[],\"right\":[{\"id\":\"nav-icon\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"header_search_responsive\"}],\"c-left\":[],\"center\":[{\"id\":\"logo\"}],\"c-right\":[],\"right\":[{\"id\":\"nav-icon\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}","logo_component_align":{"mobile":"center","tablet":"center","desktop":"center"}}',
],
[
- 'label' => 'Collapsed',
+ 'label' => __( 'Collapsed', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/ClassicCollapsed.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"header_search_responsive\"},{\"id\":\"nav-icon\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"header_search_responsive\"},{\"id\":\"nav-icon\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}"}',
],
[
- 'label' => 'Search Field',
+ 'label' => __( 'Search Field', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/SearchField.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"},{\"id\":\"primary-menu\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"header_search\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"},{\"id\":\"nav-icon\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"header_search_responsive\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"}]}}"}',
],
[
- 'label' => 'Button Item',
+ 'label' => __( 'Button Item', 'neve' ),
'image' => NEVE_ASSETS_URL . 'img/header-presets/ButtonItem.jpg',
'setup' => '{"hfg_header_layout_v2":"{\"desktop\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"primary-menu\"},{\"id\":\"button_base\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]}},\"mobile\":{\"top\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"main\":{\"left\":[{\"id\":\"logo\"}],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[{\"id\":\"nav-icon\"}]},\"bottom\":{\"left\":[],\"c-left\":[],\"center\":[],\"c-right\":[],\"right\":[]},\"sidebar\":[{\"id\":\"primary-menu\"},{\"id\":\"button_base\"}]}}"}',
],
diff --git a/header-footer-grid/Core/Components/MenuIcon.php b/header-footer-grid/Core/Components/MenuIcon.php
index 116baa1719..4105781725 100644
--- a/header-footer-grid/Core/Components/MenuIcon.php
+++ b/header-footer-grid/Core/Components/MenuIcon.php
@@ -544,13 +544,13 @@ public function add_settings() {
'default' => 'default',
'options' => [
'options' => [
- 'default' => 'Default',
- 'arrow' => 'Arrow',
- 'donner' => 'Donner',
- 'dots' => 'Dots',
- 'minus' => 'Minus',
- 'vortex' => 'Vortex',
- 'squeeze' => 'Squeeze',
+ 'default' => __( 'Default', 'neve' ),
+ 'arrow' => __( 'Arrow', 'neve' ),
+ 'donner' => __( 'Donner', 'neve' ),
+ 'dots' => __( 'Dots', 'neve' ),
+ 'minus' => __( 'Minus', 'neve' ),
+ 'vortex' => __( 'Vortex', 'neve' ),
+ 'squeeze' => __( 'Squeeze', 'neve' ),
],
'default' => 'default',
],
diff --git a/header-footer-grid/templates/components/component-footer-sidebar.php b/header-footer-grid/templates/components/component-footer-sidebar.php
index c3fe3cbaa0..7bffeb3a2a 100644
--- a/header-footer-grid/templates/components/component-footer-sidebar.php
+++ b/header-footer-grid/templates/components/component-footer-sidebar.php
@@ -30,7 +30,6 @@
/* translators: %s - customizer link */
__( 'Replace this widget content by going to %s and add widgets into this widget area.', 'neve' ), //phpcs:ignore WordPress.Security.EscapeOutput.OutputNotEscaped
sprintf(
- /* translators: %1$s - link %2$s - name %3$s - label */
'%2$s %3$s',
esc_url( admin_url( 'customize.php?autofocus[section]=sidebar-widgets-footer-' . $_id ) ),
/* translators: %1$s - → symbol %2$s - → symbol %3$s - → symbol */
diff --git a/inc/compatibility/starter-content/theme-mods.php b/inc/compatibility/starter-content/theme-mods.php
index c79050d9c8..4739f8087e 100644
--- a/inc/compatibility/starter-content/theme-mods.php
+++ b/inc/compatibility/starter-content/theme-mods.php
@@ -6,16 +6,16 @@
*/
return array(
'logo_show_tagline' => 0,
- 'nav-icon_button_appearance' =>
+ 'nav-icon_button_appearance' =>
array(
- 'borderRadius' =>
+ 'borderRadius' =>
array(
'top' => '3',
'left' => '3',
'bottom' => '3',
'right' => '3',
),
- 'borderWidth' =>
+ 'borderWidth' =>
array(
'top' => 1,
'right' => 1,
@@ -24,7 +24,7 @@
),
'useShadow' => false,
'shadowColor' => 'rgba(0,0,0,0.5)',
- 'shadowProperties' =>
+ 'shadowProperties' =>
array(
'blur' => 5,
'width' => 0,
@@ -32,7 +32,7 @@
),
'useShadowHover' => false,
'shadowColorHover' => 'rgba(0,0,0,0.5)',
- 'shadowPropertiesHover' =>
+ 'shadowPropertiesHover' =>
array(
'blur' => 5,
'width' => 0,
@@ -44,12 +44,12 @@
'text' => '',
'textHover' => '',
),
- 'hfg_header_layout_top_background' =>
+ 'hfg_header_layout_top_background' =>
array(
'type' => 'color',
'colorValue' => '#f0f0f0',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -59,11 +59,11 @@
'fixed' => false,
'useFeatured' => false,
),
- 'hfg_header_layout_main_background' =>
+ 'hfg_header_layout_main_background' =>
array(
'type' => 'color',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -74,12 +74,12 @@
'fixed' => false,
'useFeatured' => false,
),
- 'hfg_header_layout_bottom_background' =>
+ 'hfg_header_layout_bottom_background' =>
array(
'type' => 'color',
'colorValue' => '#ffffff',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -89,11 +89,11 @@
'fixed' => false,
'useFeatured' => false,
),
- 'hfg_header_layout_sidebar_background' =>
+ 'hfg_header_layout_sidebar_background' =>
array(
'type' => 'color',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -104,12 +104,12 @@
'fixed' => false,
'useFeatured' => false,
),
- 'hfg_footer_layout_top_background' =>
+ 'hfg_footer_layout_top_background' =>
array(
'type' => 'color',
'colorValue' => '#ffffff',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -119,11 +119,11 @@
'fixed' => false,
'useFeatured' => false,
),
- 'hfg_footer_layout_bottom_background' =>
+ 'hfg_footer_layout_bottom_background' =>
array(
'type' => 'color',
'imageUrl' => '',
- 'focusPoint' =>
+ 'focusPoint' =>
array(
'x' => 0.5,
'y' => 0.5,
@@ -144,14 +144,14 @@
'neve_headings_font_family' => '',
'neve_button_appearance' =>
array(
- 'borderRadius' =>
+ 'borderRadius' =>
array(
'top' => '4',
'right' => '4',
'bottom' => '4',
'left' => '4',
),
- 'borderWidth' =>
+ 'borderWidth' =>
array(
'top' => 1,
'right' => 1,
@@ -160,7 +160,7 @@
),
'useShadow' => false,
'shadowColor' => 'rgba(0,0,0,0.5)',
- 'shadowProperties' =>
+ 'shadowProperties' =>
array(
'blur' => 5,
'width' => 0,
@@ -168,7 +168,7 @@
),
'useShadowHover' => false,
'shadowColorHover' => 'rgba(0,0,0,0.5)',
- 'shadowPropertiesHover' =>
+ 'shadowPropertiesHover' =>
array(
'blur' => 5,
'width' => 0,
@@ -180,17 +180,17 @@
'text' => '#fefefe',
'textHover' => '#ffffff',
),
- 'neve_h1_typeface_general' =>
+ 'neve_h1_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.2',
'tablet' => '1.3',
@@ -202,7 +202,7 @@
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '39',
'tablet' => '55',
@@ -219,17 +219,17 @@
'neve_container_width' => '{"mobile":748,"tablet":992,"desktop":1170}',
'neve_default_container_style' => 'contained',
'neve_text_color' => '#2b2b2b',
- 'neve_h2_typeface_general' =>
+ 'neve_h2_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.3',
'tablet' => '1.3',
@@ -241,7 +241,7 @@
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '28',
'tablet' => '34',
@@ -255,34 +255,34 @@
),
'flag' => false,
),
- 'neve_h3_typeface_general' =>
+ 'neve_h3_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.3',
'tablet' => '1.3',
'desktop' => '1.3',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '20',
'tablet' => '20',
'desktop' => '24',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -295,11 +295,11 @@
'neve_other_pages_sidebar_layout' => 'full-width',
'neve_single_post_content_width' => 70,
'neve_other_pages_content_width' => 100,
- 'neve_typeface_general' =>
+ 'neve_typeface_general' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -309,19 +309,19 @@
'tablet' => 16,
'desktop' => '18',
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.7',
'tablet' => '1.7',
'desktop' => 1.7,
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
@@ -334,11 +334,11 @@
'primary-menu_color' => 'var(--nv-text-color)',
'primary-menu_active_color' => 'var(--nv-text-color)',
'primary-menu_hover_color' => 'var(--nv-secondary-accent)',
- 'primary-menu_component_typeface' =>
+ 'primary-menu_component_typeface' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
@@ -348,13 +348,13 @@
'tablet' => 1,
'desktop' => 0.8,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => 1.6,
'tablet' => 1.6,
'desktop' => 1.6,
),
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
@@ -366,16 +366,16 @@
'neve_grid_layout' => '{"desktop":2,"tablet":2,"mobile":1}',
'neve_link_color' => '#2b2b2b',
'neve_link_hover_color' => '#727272',
- 'neve_secondary_button_appearance' =>
+ 'neve_secondary_button_appearance' =>
array(
- 'borderRadius' =>
+ 'borderRadius' =>
array(
'top' => '4',
'right' => '4',
'bottom' => '4',
'left' => '4',
),
- 'borderWidth' =>
+ 'borderWidth' =>
array(
'top' => '2',
'right' => '2',
@@ -384,7 +384,7 @@
),
'useShadow' => false,
'shadowColor' => 'rgba(0,0,0,0.5)',
- 'shadowProperties' =>
+ 'shadowProperties' =>
array(
'blur' => 5,
'width' => 0,
@@ -392,7 +392,7 @@
),
'useShadowHover' => false,
'shadowColorHover' => 'rgba(0,0,0,0.5)',
- 'shadowPropertiesHover' =>
+ 'shadowPropertiesHover' =>
array(
'blur' => 5,
'width' => 0,
@@ -405,23 +405,23 @@
'textHover' => 'var(--nv-text-dark-bg)',
),
'logo_max_width' => '{"mobile":32,"tablet":32,"desktop":32}',
- 'neve_button_padding' =>
+ 'neve_button_padding' =>
array(
- 'mobile' =>
+ 'mobile' =>
array(
'top' => '12',
'right' => '24',
'bottom' => '12',
'left' => '24',
),
- 'tablet' =>
+ 'tablet' =>
array(
'top' => '12',
'right' => '24',
'bottom' => '12',
'left' => '24',
),
- 'desktop' =>
+ 'desktop' =>
array(
'top' => '12',
'right' => '24',
@@ -432,23 +432,23 @@
'tablet-unit' => 'px',
'desktop-unit' => 'px',
),
- 'neve_secondary_button_padding' =>
+ 'neve_secondary_button_padding' =>
array(
- 'mobile' =>
+ 'mobile' =>
array(
'top' => '12',
'right' => '24',
'bottom' => '12',
'left' => '24',
),
- 'tablet' =>
+ 'tablet' =>
array(
'top' => '12',
'right' => '24',
'bottom' => '12',
'left' => '24',
),
- 'desktop' =>
+ 'desktop' =>
array(
'top' => '12',
'right' => '24',
@@ -460,34 +460,34 @@
'desktop-unit' => 'px',
),
'neve_blog_list_alternative_layout' => true,
- 'neve_h4_typeface_general' =>
+ 'neve_h4_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.3',
'tablet' => '1.3',
'desktop' => '1.3',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '16',
'tablet' => '16',
'desktop' => '20',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -496,34 +496,34 @@
),
'flag' => false,
),
- 'neve_h5_typeface_general' =>
+ 'neve_h5_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.3',
'tablet' => '1.3',
'desktop' => '1.3',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '14',
'tablet' => '14',
'desktop' => '16',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -532,34 +532,34 @@
),
'flag' => false,
),
- 'neve_h6_typeface_general' =>
+ 'neve_h6_typeface_general' =>
array(
'fontWeight' => '600',
'textTransform' => 'none',
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
'desktop' => 0,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => '1.3',
'tablet' => '1.3',
'desktop' => '1.3',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'fontSize' =>
+ 'fontSize' =>
array(
'mobile' => '14',
'tablet' => '14',
'desktop' => '16',
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -568,16 +568,17 @@
),
'flag' => false,
),
- 'neve_global_colors' =>
+ 'neve_global_colors' =>
array(
'activePalette' => 'base',
- 'palettes' =>
+ 'palettes' =>
array(
- 'base' =>
+ 'base' =>
array(
- 'name' => 'Base',
+ // translators: name of the color pallet.
+ 'name' => __( 'Base', 'neve' ),
'allowDeletion' => false,
- 'colors' =>
+ 'colors' =>
array(
'nv-primary-accent' => '#0065cb',
'nv-secondary-accent' => '#0057ad',
@@ -590,11 +591,11 @@
'nv-c-2' => '#f37262',
),
),
- 'darkMode' =>
+ 'darkMode' =>
array(
- 'name' => 'Dark Mode',
+ 'name' => __( 'Dark Mode', 'neve' ),
'allowDeletion' => false,
- 'colors' =>
+ 'colors' =>
array(
'nv-primary-accent' => '#0065cb',
'nv-secondary-accent' => '#0057ad',
@@ -607,11 +608,12 @@
'nv-c-2' => '#f37262',
),
),
- 'eastBay' =>
+ 'eastBay' =>
array(
- 'name' => 'East Bay',
+ // translators: name of the color pallet.
+ 'name' => __( 'East Bay', 'neve' ),
'allowDeletion' => true,
- 'colors' =>
+ 'colors' =>
array(
'nv-primary-accent' => '#4b547d',
'nv-secondary-accent' => '#3f4669',
@@ -624,11 +626,11 @@
'nv-c-2' => '#f37262',
),
),
- 'green' =>
+ 'green' =>
array(
- 'name' => 'Green',
+ 'name' => __( 'Green', 'neve' ),
'allowDeletion' => true,
- 'colors' =>
+ 'colors' =>
array(
'nv-primary-accent' => '#04724d',
'nv-secondary-accent' => '#04583c',
@@ -645,11 +647,11 @@
),
'hfg_footer_layout_bottom_new_text_color' => 'var(--nv-text-dark-bg)',
'logo_display' => 'logoTitle',
- 'neve_button_typeface' =>
+ 'neve_button_typeface' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -660,9 +662,9 @@
'desktop' => '18',
),
'flag' => false,
- 'lineHeight' =>
+ 'lineHeight' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
@@ -674,11 +676,11 @@
),
'textTransform' => 'capitalize',
),
- 'neve_secondary_button_typeface' =>
+ 'neve_secondary_button_typeface' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -691,7 +693,7 @@
'flag' => false,
),
'neve_fallback_font_family' => 'Arial, Helvetica, sans-serif',
- 'neve_form_fields_padding' =>
+ 'neve_form_fields_padding' =>
array(
'top' => '10',
'bottom' => 10,
@@ -700,7 +702,7 @@
'unit' => 'px',
),
'neve_form_button_type' => 'primary',
- 'neve_form_fields_border_radius' =>
+ 'neve_form_fields_border_radius' =>
array(
'top' => '0',
'right' => '0',
@@ -708,11 +710,11 @@
'bottom' => '0',
'unit' => 'px',
),
- 'neve_archive_typography_post_title' =>
+ 'neve_archive_typography_post_title' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -723,9 +725,9 @@
'desktop' => '32',
),
'flag' => false,
- 'lineHeight' =>
+ 'lineHeight' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
@@ -736,11 +738,11 @@
'desktop' => '',
),
),
- 'neve_single_post_typography_post_title' =>
+ 'neve_single_post_typography_post_title' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'px',
'tablet' => 'px',
@@ -751,9 +753,9 @@
'desktop' => '65',
),
'flag' => true,
- 'lineHeight' =>
+ 'lineHeight' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
@@ -766,7 +768,7 @@
),
'neve_had_old_skin' => false,
'footer_copyright_color' => 'var(--nv-text-dark-bg)',
- 'footer_copyright_component_align' =>
+ 'footer_copyright_component_align' =>
array(
'desktop' => 'center',
'tablet' => 'center',
@@ -775,11 +777,11 @@
'hfg_footer_layout_v2' => '{"desktop":{"top":{"left":[],"c-left":[],"center":[],"c-right":[],"right":[]},"main":{"left":[],"c-left":[],"center":[],"c-right":[],"right":[]},"bottom":{"left":[],"c-left":[{"id":"footer_copyright"},{"id":"footer-menu"}],"center":[],"c-right":[],"right":[]}}}',
'neve_form_fields_spacing' => 4,
'neve_form_fields_background_color' => 'var(--nv-site-bg)',
- 'footer_copyright_component_typeface' =>
+ 'footer_copyright_component_typeface' =>
array(
- 'fontSize' =>
+ 'fontSize' =>
array(
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
@@ -789,19 +791,19 @@
'tablet' => 1,
'desktop' => 1,
),
- 'lineHeight' =>
+ 'lineHeight' =>
array(
'mobile' => 1.6,
'tablet' => 1.6,
'desktop' => 1.6,
- 'suffix' =>
+ 'suffix' =>
array(
'mobile' => 'em',
'tablet' => 'em',
'desktop' => 'em',
),
),
- 'letterSpacing' =>
+ 'letterSpacing' =>
array(
'mobile' => 0,
'tablet' => 0,
@@ -813,13 +815,13 @@
'neve_layout_single_post_elements_order' => '["content","tags","comments"]',
'neve_post_header_layout' => 'cover',
'neve_post_cover_height' => '{"mobile":250,"tablet":30,"desktop":50,"suffix":{"tablet":"vh","desktop":"vh","mobile":"px"}}',
- 'neve_post_title_alignment' =>
+ 'neve_post_title_alignment' =>
array(
'mobile' => 'left',
'tablet' => 'left',
'desktop' => 'left',
),
- 'neve_post_title_position' =>
+ 'neve_post_title_position' =>
array(
'mobile' => 'center',
'tablet' => 'center',
@@ -833,23 +835,23 @@
'neve_post_thumbnail_box_shadow' => 0,
'primary-menu_style' => 'style-border-top',
'neve_post_cover_background_color' => 'var(--nv-secondary-accent)',
- 'neve_post_cover_padding' =>
+ 'neve_post_cover_padding' =>
array(
- 'mobile' =>
+ 'mobile' =>
array(
'top' => 40,
'right' => 15,
'bottom' => 40,
'left' => 15,
),
- 'tablet' =>
+ 'tablet' =>
array(
'top' => 60,
'right' => 30,
'bottom' => 60,
'left' => 30,
),
- 'desktop' =>
+ 'desktop' =>
array(
'top' => 60,
'right' => 40,
@@ -862,23 +864,23 @@
),
'neve_post_cover_overlay_opacity' => 80,
'neve_post_cover_container' => 'contained',
- 'neve_post_cover_title_boxed_padding' =>
+ 'neve_post_cover_title_boxed_padding' =>
array(
- 'mobile' =>
+ 'mobile' =>
array(
'top' => 40,
'right' => 15,
'bottom' => 40,
'left' => 15,
),
- 'tablet' =>
+ 'tablet' =>
array(
'top' => 60,
'right' => 30,
'bottom' => 60,
'left' => 30,
),
- 'desktop' =>
+ 'desktop' =>
array(
'top' => 60,
'right' => 40,
@@ -890,7 +892,7 @@
'desktop-unit' => 'px',
),
'neve_single_post_meta_ordering' => '["author","date"]',
- 'neve_form_fields_border_width' =>
+ 'neve_form_fields_border_width' =>
array(
'top' => '2',
'right' => '2',
@@ -900,7 +902,7 @@
),
'neve_form_fields_border_color' => 'var(--nv-light-bg)',
'neve_input_text_color' => 'var(--nv-text-color)',
- 'footer-menu_component_align' =>
+ 'footer-menu_component_align' =>
array(
'desktop' => 'right',
'tablet' => 'left',
@@ -910,5 +912,5 @@
'custom_logo' => '{{featured-image-logo}}',
'logo_color' => 'var(--nv-text-color)',
'neve_enable_featured_post' => true,
- 'neve_blog_post_meta_fields' => '[{"slug":"author","title":"Author","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"comments","title":"Comments","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"category","title":"Category","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"date","title":"Date","visibility":"no","hide_on_mobile":"","blocked":"yes"}]',
+ 'neve_blog_post_meta_fields' => '[{"slug":"author","title":"' . __( 'Author', 'neve' ) . '","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"comments","title":"' . __( 'Comments', 'neve' ) . '","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"category","title":"' . __( 'Category', 'neve' ) . '","visibility":"yes","hide_on_mobile":"","blocked":"yes"},{"slug":"date","title":"' . __( 'Date', 'neve' ) . '","visibility":"no","hide_on_mobile":"","blocked":"yes"}]',
);
diff --git a/phpcs.xml b/phpcs.xml
index 33bd72459f..a0fc3f081a 100644
--- a/phpcs.xml
+++ b/phpcs.xml
@@ -1,32 +1,33 @@
- Themeisle rules for PHP_CodeSniffer.
+ Themeisle rules for PHP_CodeSniffer.
- .
+ .
- node_modules/*
- dist/*
- vendor/*
- tests/*
- *.min.js
- *.min.css
- *.js
- *.css
+ node_modules/*
+ dist/*
+ vendor/*
+ tests/*
+ *.min.js
+ *.min.css
+ *.js
+ *.css
*.asset.php
globals/google-fonts.php
-
+
-
-
+
-
+
-
+
@@ -35,8 +36,8 @@
views/page-header.php
-
-
+
+
-
-
+
+
\ No newline at end of file
From 3deb66310817f7c45727da29fb505b616c0d46cc Mon Sep 17 00:00:00 2001
From: "Soare Robert Daniel (Mac 2023)"
Date: Tue, 10 Dec 2024 15:54:27 +0200
Subject: [PATCH 2/3] fix: replace ExternalLink component with anchor tag for
external documentation link
---
assets/apps/dashboard/src/Components/FeatureRow.js | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/assets/apps/dashboard/src/Components/FeatureRow.js b/assets/apps/dashboard/src/Components/FeatureRow.js
index 4a29e7022f..eb27cb1c8d 100644
--- a/assets/apps/dashboard/src/Components/FeatureRow.js
+++ b/assets/apps/dashboard/src/Components/FeatureRow.js
@@ -97,11 +97,12 @@ const FeatureRow = ({ item }) => {
),
{
external_link: (
-
#dumptext
-
+
),
}
)}
From a964e9aa941a26c07a912b6e57708fada1482e90 Mon Sep 17 00:00:00 2001
From: "Soare Robert Daniel (Mac 2023)"
Date: Thu, 12 Dec 2024 10:39:42 +0200
Subject: [PATCH 3/3] fix: add translation functions for font preview text
---
.../src/typography-font-pair/FontPairSelector.tsx | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/assets/apps/customizer-controls/src/typography-font-pair/FontPairSelector.tsx b/assets/apps/customizer-controls/src/typography-font-pair/FontPairSelector.tsx
index 752f6dd9bb..bc9d327925 100644
--- a/assets/apps/customizer-controls/src/typography-font-pair/FontPairSelector.tsx
+++ b/assets/apps/customizer-controls/src/typography-font-pair/FontPairSelector.tsx
@@ -188,13 +188,13 @@ const FontPairSelector: React.FC = ({
className="neve-font-preview"
style={headingStyle}
>
- The big brown fox
+ {__('The big brown fox', 'neve')}
- Jumps over the lazy dog
+ {__('Jumps over the lazy dog', 'neve')}