# -*- coding: utf-8 -*-
from django import forms


class ColorPickerWidget(forms.TextInput):
    # todo: test me
    def __init__(self, *args, **kwargs):
        super(ColorPickerWidget, self).__init__(*args, **kwargs)
        self.attrs['class'] = 'colorpicker'

    class Media:
        css = {
            'all': ('admin/plugins/jquery-miniColors/jquery.miniColors.css',)
        }
        js = [
#            'admin/js/jquery-1.7.2.min.js',
            'admin/plugins/jquery-miniColors/jquery.miniColors.js',
            'admin/js/init_colorpicker.js',
        ]


class NumberInput(forms.TextInput):
    input_type = 'number'
