mirror of
https://github.com/EGroupware/egroupware.git
synced 2025-01-03 04:29:28 +01:00
WIP implementing colorpicker widget
This commit is contained in:
parent
61da5c544a
commit
53f156a66b
40
api/js/etemplate/Et2Colorpicker/Et2Colorpicker.ts
Normal file
40
api/js/etemplate/Et2Colorpicker/Et2Colorpicker.ts
Normal file
@ -0,0 +1,40 @@
|
||||
/**
|
||||
* EGroupware eTemplate2 - Colorpicker widget (WebComponent)
|
||||
*
|
||||
* @license http://opensource.org/licenses/gpl-license.php GPL - GNU General Public License
|
||||
* @package etemplate
|
||||
* @subpackage api
|
||||
* @link https://www.egroupware.org
|
||||
* @author Hadi Nategh
|
||||
*/
|
||||
|
||||
|
||||
|
||||
import {html} from "@lion/core";
|
||||
import {LionInput} from "@lion/input";
|
||||
import {Et2Widget} from "../Et2Widget/Et2Widget";
|
||||
import {Et2InputWidget} from "../Et2InputWidget/Et2InputWidget";
|
||||
|
||||
export class Et2Colorpicker extends Et2InputWidget(Et2Widget(LionInput))
|
||||
{
|
||||
|
||||
constructor()
|
||||
{
|
||||
super();
|
||||
}
|
||||
|
||||
connectedCallback()
|
||||
{
|
||||
super.connectedCallback();
|
||||
}
|
||||
|
||||
render()
|
||||
{
|
||||
return html`
|
||||
<div class="et2_colorpicker" id="${this.id}">
|
||||
<input class="et2_colorpicker" type="color" />
|
||||
</div>
|
||||
`;
|
||||
}
|
||||
}
|
||||
customElements.define('et2-colorpicker', Et2Colorpicker);
|
@ -28,6 +28,7 @@ import './Et2Button/Et2Button';
|
||||
import './Et2Date/Et2Date';
|
||||
import './Et2Textarea/Et2Textarea';
|
||||
import './Et2Textbox/Et2Textbox';
|
||||
import './Et2Colorpicker/Et2Colorpicker';
|
||||
/* Include all widget classes here, we only care about them registering, not importing anything*/
|
||||
import './et2_widget_vfs'; // Vfs must be first (before et2_widget_file) due to import cycle
|
||||
import './et2_widget_template';
|
||||
|
Loading…
Reference in New Issue
Block a user