[wordpress插件] CSS Crush for WordPressWordPress的CSS Crush

wordpress 插件 文章 2020-04-06 01:50 431 0 全屏看文

AI助手支持GPT4.0

评分
0
描述

CSS allows you to do lots of things, but some features are missing to developers.

CSS允许您做很多事情,但是开发人员缺少某些功能。

What about variables, constants, and general faster syntax?

变量,常量和一般更快的语法呢?

Normal CSS can not do that, that is why you have preprocessors, like CSS Crush.

普通的CSS不能做到这一点,这就是为什么要使用CSS Crush之类的预处理器的原因。

CSS Crush for WordPress allows the use of variables in CSS files.

WordPress的CSS Crush允许在CSS文件中使用变量。

This plugin will automaticly process all your theme’s stylesheets for you!

此插件将自动为您处理您所有主题的样式表!

No configuration needed.

无需配置。

However, you can customize it from the Settings page.

但是,您可以从“设置”页面对其进行自定义。

By default your stylesheet will be minified, cached and have it’s vendor prefixes automatically generated.

默认情况下,您的样式表将被缩小 cached 并自动生成供应商前缀

examples of generated prefixes

生成的前缀示例

/* Before */

  / *之前* /

div { background: red linear-gradient( left, red, white );

div {背景:红色线性渐变(左,红,白);

}

}

/* After */

/ *在* /之后

div {  

div {  

background: red -webkit-linear-gradient( left, red, white );  

背景:红色-webkit-linear-gradient(左,红,白);  

background: red -moz-linear-gradient( left, red, white );  

背景:红色-moz-linear-gradient(左侧,红色,白色);  

background: red -o-linear-gradient( left, red, white );  

背景:红色-o-linear-gradient(左,红,白);  

background: red linear-gradient( left, red, white );

背景:红色线性渐变(左,红,白);

}

}

example with the use of variables

使用变量的示例

/* Defining variables */

  / *定义变量* /

@define {    

@define {    

brand-blue: #C1D9F5;    

蓝色:#C1D9F5;    

helvetica: "Helvetica Neue", Helvetica, Arial, sans-serif;

Helvetica:“ Helvetica Neue”,Helvetica,Arial,无衬线;

}

}

ul, p {    

ul,p {    

font-family: $( helvetica );    

字体家族:$(helvetica);    

color: $( brand-blue );

颜色:$(brand-blue);

}

}

More Features

更多功能

    • Declare variables in your CSS
    • 在CSS中声明变量

    • Direct @import
    • 直接@import

    • A small collection of custom math functions are built-in
    • 内置少量自定义数学函数

    • Block nesting
    • 块嵌套

    • The experimental :any pseudo class is supported
    • 实验性:支持任何伪类

    Current CSS Crush version: 1.6.1

    当前CSS Crush版本:1.6.1

    For a full list of features please visit http://the-echoplex.net/csscrush/

    有关功能的完整列表,请访问 http://the-echoplex.net/csscrush/

    >.

    >。

    Related Links:

    相关链接:

      • http://www.codepress.nl/plugins/
      • http://www.codepress.nl/plugins/

      Translations

      翻译

      If you like to contribute a language, please send them to info@codepress.nl.

      如果您想贡献一种语言,请将其发送到 info@codepress.nl

安装步骤

    1. Upload css-crush-for-wordpress to the /wp-content/plugins/ directory
    2. 将css-crush-for-wordpress上载到/ wp-content / plugins /目录

    3. Activate CSS Crush for WordPress through the ‘Plugins’ menu in WordPress
    4. 通过WordPress中的“插件”菜单激活WordPress的CSS Crush

    5. Configure the plugin by going to the CSS Crush settings that appears under the Settings menu.
    6. 通过转到“设置”菜单下显示的“ CSS Crush”设置来配置插件。

下载地址
https://downloads.wordpress.org/plugin/css-crush-for-wordpress.0.3.zip
-EOF-

AI助手支持GPT4.0