2.2.1.1. CSS Class Manager

Warning

You are looking at documentation for an older release. Not what you want? See the current release documentation.

This plugin is used to manage CSS class of file icons.

You can find the configuration file of this component at: commons-extension.war!/WEB-INF/conf/commons-extension/css-class-configuration.xml.

To use the plugin in the component configuration, you must configure the following target-component:


<target-component>org.exoplatform.webui.cssfile.CssClassManager</target-component>

Sample Configuration



<external-component-plugins>
    <target-component>org.exoplatform.webui.cssfile.CssClassManager</target-component>
    <component-plugin>
        <name>forum.default.cssclass</name>
        <set-method>registerCssClassPlugin</set-method>
        <type>org.exoplatform.webui.cssfile.CssClassPlugin</type>
        <description>default supported CSS class icon file</description>
        <init-params>
            <object-param>
                <name>default</name>
                <description></description>
                <object type="org.exoplatform.webui.cssfile.CssClassIconFile">
                    <field name="type">
                        <string>default</string>
                    </field>
                    <field name="cssClass">
                        <string>FileDefault</string>
                    </field>
                    <field name="groupFileTypes">
                        <string><![CDATA[applicationoctet-stream]]></string>
                    </field>
                </object>
            </object-param>
            ...
            <object-param>
                <name>zip</name>
                <description></description>
                <object type="org.exoplatform.webui.cssfile.CssClassIconFile">
                    <field name="type">
                        <string>zip</string>
                    </field>
                    <field name="cssClass">
                        <string>FileArchiveZip</string>
                    </field>
                    <field name="groupFileTypes">
                        <string><![CDATA[FileZip,applicationzip]]></string>
                    </field>
                </object>
            </object-param>
            ...
        </init-params>
    </component-plugin>
</external-component-plugins>

In which:

FieldTypeDescription
typestringThe file extension.
cssClassstringThe CSS class which is corresponding to the file extension.
groupFileTypesstringThe list of file types which have the same CSS class as the file extension.
Copyright ©. All rights reserved. eXo Platform SAS
blog comments powered byDisqus