File tree Expand file tree Collapse file tree 2 files changed +6
-10
lines changed
Expand file tree Collapse file tree 2 files changed +6
-10
lines changed Original file line number Diff line number Diff line change 11import CollapsibleComponent from "./collapsible_component" ;
22
33class ClockCollapsible extends CollapsibleComponent {
4- key = 'clock' ;
5- retrieves = {
4+ loads = {
65 'clock' : 'clock'
76 } ;
8- changes = {
7+
8+ watchers = {
99 'clock' : this . changed
1010 } ;
1111
Original file line number Diff line number Diff line change 11export default class CollapsibleComponent {
22 initialized = false ;
33 retrieves = { } ;
4- changes = { } ;
4+ watchers = { } ;
55
66 load ( static_data ) {
77 if ( ! static_data ) {
@@ -15,8 +15,8 @@ export default class CollapsibleComponent {
1515 this . calendar_settings = static_data . settings ;
1616
1717 if ( ! this . initialized ) {
18- for ( let localKey of Object . keys ( this . changes ) ) {
19- this . $watch ( localKey , this . changes [ localKey ] . bind ( this ) ) ;
18+ for ( let localKey of Object . keys ( this . watchers ) ) {
19+ this . $watch ( localKey , this . watchers [ localKey ] . bind ( this ) ) ;
2020 }
2121
2222 this . initialized = true ;
@@ -28,8 +28,4 @@ export default class CollapsibleComponent {
2828 loaded ( static_data ) {
2929 // throw new Error(`The component ${this.prototype.constructor.name} must implement 'changed()'!`);
3030 }
31-
32- changed ( ) {
33- // throw new Error(`The component ${this.prototype.constructor.name} must implement 'changed()'!`);
34- }
3531}
You can’t perform that action at this time.
0 commit comments