File tree 2 files changed +8
-5
lines changed
2 files changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -79,9 +79,10 @@ const metadata = {
79
79
*
80
80
* @event
81
81
* @public
82
+ * @since 1.0.0-rc.15
82
83
* @param {String } color the selected color
83
84
*/
84
- change : {
85
+ "item-click" : {
85
86
details : {
86
87
color : {
87
88
type : String ,
@@ -196,7 +197,7 @@ class ColorPalette extends UI5Element {
196
197
}
197
198
}
198
199
199
- this . fireEvent ( "change " , {
200
+ this . fireEvent ( "item-click " , {
200
201
color : this . _selectedColor ,
201
202
} ) ;
202
203
}
Original file line number Diff line number Diff line change 58
58
< br />
59
59
< br />
60
60
< br />
61
- < ui5-input id ="changeResult " value ="Nothing selected "> </ ui5-input >
61
+ < ui5-input id ="itemClickResult " value ="Nothing selected "> </ ui5-input >
62
62
< br >
63
63
< ui5-button id ="colorPaletteBtn " > Open ColorPalette</ ui5-button >
64
64
< ui5-responsive-popover id ="respPopover " with-padding >
125
125
</ ui5-color-palette >
126
126
127
127
< script >
128
- cp1 . addEventListener ( "change " , function ( event ) {
129
- changeResult . value = event . detail . color ;
128
+ cp1 . addEventListener ( "item-click " , function ( event ) {
129
+ itemClickResult . value = event . detail . color ;
130
130
} ) ;
131
+
131
132
colorPaletteBtn . addEventListener ( "click" , function ( event ) {
132
133
respPopover . open ( colorPaletteBtn ) ;
133
134
} ) ;
135
+
134
136
btnClose . addEventListener ( "click" , function ( event ) {
135
137
respPopover . close ( ) ;
136
138
} ) ;
You can’t perform that action at this time.
0 commit comments