menu

ASP.NET MVC - EJ2

  • Code Examples
  • Upgrade Guide
  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class ColorPicker - API Reference

    Show / Hide Table of Contents

    Class ColorPicker

    Inheritance
    System.Object
    TagHelper
    EJTagHelper
    ColorPicker
    Inherited Members
    EJTagHelper.GetList()
    EJTagHelper.GetSerializedProperties()
    EJTagHelper.GetScriptString()
    EJTagHelper.GetHtmlAttrString(IDictionary<String, Object>)
    EJTagHelper.TagName
    EJTagHelper.Id
    EJTagHelper.NameSpace
    EJTagHelper.ClassName
    EJTagHelper.IsFor
    EJTagHelper.IsChild
    EJTagHelper.IsComplex
    EJTagHelper.IsCollection
    EJTagHelper.ParentPropertyName
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Syncfusion.EJ2.Inputs
    Assembly: Syncfusion.EJ2.dll
    Syntax
    public class ColorPicker : EJTagHelper

    Constructors

    ColorPicker()

    Declaration
    public ColorPicker()

    Properties

    BeforeClose

    Triggers before closing the ColorPicker popup.

    Declaration
    [HtmlAttributeName("beforeClose")]
    public string BeforeClose { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    BeforeModeSwitch

    Triggers before Switching between ColorPicker mode.

    Declaration
    [HtmlAttributeName("beforeModeSwitch")]
    public string BeforeModeSwitch { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    BeforeOpen

    Triggers before opening the ColorPicker popup.

    Declaration
    [HtmlAttributeName("beforeOpen")]
    public string BeforeOpen { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    BeforeTileRender

    Trigger while rendering each palette tile.

    Declaration
    [HtmlAttributeName("beforeTileRender")]
    public string BeforeTileRender { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Change

    Triggers while changing the colors. It will be triggered based on the showButtons property. If the property is false, the event will be triggered while selecting the colors. If the property is true, the event will be triggered while apply the selected color.

    Declaration
    [HtmlAttributeName("change")]
    public string Change { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Columns

    It is used to render the ColorPicker palette with specified columns.

    Declaration
    [HtmlAttributeName("columns")]
    public double Columns { get; set; }
    Property Value
    Type Description
    System.Double

    The default value is 10

    Created

    Triggers once the component rendering is completed.

    Declaration
    [HtmlAttributeName("created")]
    public string Created { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    CreatePopupOnClick

    Specifies the popup element creation on open.

    Declaration
    [HtmlAttributeName("createPopupOnClick")]
    public bool CreatePopupOnClick { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    CssClass

    This property sets the CSS classes to root element of the ColorPicker which helps to customize the UI styles.

    Declaration
    [HtmlAttributeName("cssClass")]
    public string CssClass { get; set; }
    Property Value
    Type Description
    System.String

    The default value is ""

    Disabled

    It is used to enable / disable ColorPicker component. If it is disabled the ColorPicker popup won’t open.

    Declaration
    [HtmlAttributeName("disabled")]
    public bool Disabled { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    EnableOpacity

    It is used to enable / disable the opacity option of ColorPicker component.

    Declaration
    [HtmlAttributeName("enableOpacity")]
    public bool EnableOpacity { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    EnablePersistence

    To enable or disable persisting component's state between page reloads and it is extended from component class.

    Declaration
    [HtmlAttributeName("enablePersistence")]
    public bool EnablePersistence { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    EnableRtl

    Enable or disable rendering component in right to left direction.

    Declaration
    [HtmlAttributeName("enableRtl")]
    public bool EnableRtl { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    HtmlAttributes

    Allows additional HTML attributes such as title, name, etc., and accepts n number of attributes in a key-value pair format.

    Declaration
    [HtmlAttributeName("htmlAttributes")]
    public object HtmlAttributes { get; set; }
    Property Value
    Type Description
    System.Object

    Inline

    It is used to render the ColorPicker component as inline.

    Declaration
    [HtmlAttributeName("inline")]
    public bool Inline { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    Locale

    Overrides the global culture and localization value for this component. Default global culture is 'en-US'.

    Declaration
    [HtmlAttributeName("locale")]
    public string Locale { get; set; }
    Property Value
    Type Description
    System.String

    The default value is ""

    Mode

    It is used to render the ColorPicker with the specified mode.

    Declaration
    [HtmlAttributeName("mode")]
    public ColorPickerMode Mode { get; set; }
    Property Value
    Type Description
    ColorPickerMode

    The default value is ColorPickerMode.Picker

    ModeSwitcher

    It is used to show / hide the mode switcher button of ColorPicker component.

    Declaration
    [HtmlAttributeName("modeSwitcher")]
    public bool ModeSwitcher { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    NoColor

    It is used to enable / disable the no color option of ColorPicker component.

    Declaration
    [HtmlAttributeName("noColor")]
    public bool NoColor { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false

    OnModeSwitch

    Triggers after Switching between ColorPicker mode.

    Declaration
    [HtmlAttributeName("onModeSwitch")]
    public string OnModeSwitch { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    Open

    Triggers while opening the ColorPicker popup.

    Declaration
    [HtmlAttributeName("open")]
    public string Open { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    PresetColors

    It is used to load custom colors to palette.

    Declaration
    [HtmlAttributeName("presetColors")]
    public object PresetColors { get; set; }
    Property Value
    Type Description
    System.Object

    The default value is null

    Select

    Triggers while selecting the color in picker / palette, when showButtons property is enabled.

    Declaration
    [HtmlAttributeName("select")]
    public string Select { get; set; }
    Property Value
    Type Description
    System.String

    The default value is null

    ShowButtons

    It is used to show / hide the control buttons (apply / cancel) of ColorPicker component.

    Declaration
    [HtmlAttributeName("showButtons")]
    public bool ShowButtons { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is true

    Value

    It is used to set the color value for ColorPicker. It should be specified as Hex code.

    Declaration
    [HtmlAttributeName("value")]
    public string Value { get; set; }
    Property Value
    Type Description
    System.String

    The default value is "#008000ff"

    Back to top Generated by DocFX
    Copyright © 2001 - 2023 Syncfusion Inc. All Rights Reserved