Warning: file_get_contents(/data/phpspider/zhask/data//catemap/8/magento/5.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Magento 变量@theme\uuuuu color\uuuuuu primary-alt未定义_Magento_Magento2_Magento 2.3 - Fatal编程技术网

Magento 变量@theme\uuuuu color\uuuuuu primary-alt未定义

Magento 变量@theme\uuuuu color\uuuuuu primary-alt未定义,magento,magento2,magento-2.3,Magento,Magento2,Magento 2.3,编译时,使用php bin/magento设置:static content:deploy-f 我得到下面的错误 Deploy using quick strategy frontend/Magento/blank/en_US 2388/2778 ========================>--- 85% % 2 secs Compilation from source: /var/www/html/vendor/magento/th

编译时,使用php bin/magento设置:static content:deploy-f

我得到下面的错误

Deploy using quick strategy
frontend/Magento/blank/en_US            2388/2778           
========================>--- 85% %   2 secs

Compilation from source: /var/www/html/vendor/magento/theme- 
frontend-blank/web/css/styles-m.less

variable @theme__color__primary-alt is undefined in 
文件var/www/html/var/view_preprocessed/pub/static/frontend/Magento/b lank/en_US/Magento_Braintree/css/source/_module.less in _module.less在第13行第26列 11| 12 |@braintree-error\uuu color:@message-error\uu color; 13 |@braintree-focus\uuuu color:@theme\uuu color\uuu primary-alt; 14 |@braintree-success\uuu color:@message-success\uu color; 15 |


我安装了一个主题。

您的本地主题似乎覆盖了基本主题_colors.less文件(开发人员必须在为magento创建自己的主题时复制粘贴此文件。/vendor/magento/magento2 base/lib/web/css/source/lib/variables/_colors.less)。有两种方法可以解决这个问题

  • 您可以在主题中扩展.less,而不是将所有主题文件复制粘贴到您自己的主题中
  • 您可以比较、检查并将升级版本中的新变量复制到您自己的主题中

  • 您的本地主题似乎覆盖了基本主题_colors.less文件(开发人员必须在为magento/vendor/magento/magento2 base/lib/web/css/source/lib/variables/_colors.less创建自己的主题时复制粘贴此文件)。有两种方法可以解决这个问题

  • 您可以在主题中扩展.less,而不是将所有主题文件复制粘贴到您自己的主题中
  • 您可以比较、检查并将升级版本中的新变量复制到您自己的主题中

  • 你有什么解决办法吗?回答:你有什么解决办法吗?回复
    frontend/Magento/blank/en_US            2695/2778           
    ===========================> 97% %   3 secs
    
    Compilation from source: /var/www/html/vendor/magento/theme- 
    frontend-blank/web/css/styles-l.less
    
    variable @theme__color__primary-alt is undefined in filevar/www/html/var/view_preprocessed/pub/static/frontend/Magento/bla 
    nk/en_US/Magento_Braintree/css/source/_module.less in _module.less 
    on line 13, column 26
    11| 
    12| @braintree-error__color: @message-error__color;
    13| @braintree-focus__color: @theme__color__primary-alt;
    14| @braintree-success__color: @message-success__color;
    15| 
    16| @braintree-paypal-icon__height: 16px;
    
    In File.php line 151:
    
    The contents from the 
    "/var/www/html/pub/static/frontend/Magento/blank/en_US/css/styles- 
    m.css" file can't be read. 
    
    Warning!file_get_contents(/var/www/html/pub/static/front  
    end/Magento/blank/en_US/css/styles-m.css): failed to open stream: 
    No such file or directory