Passing class method as callback to another class in javascript

I am trying to create a pop up menu (via a class) called from another class. After these inputs are filled in I want the input data to be processed by the object from which the pop up menu was initiated.

My thought process created the following code (simplified ofc):

class foo{
        constructor(){
            this.prroperty = 'yes';
        }

        eventMethod(){
            let eventForm = new bar();
            eventForm.fire(this.endMethod);
        }

        endMethod(values){
            // console.log(this);
            console.log(values + this.prroperty);
        }
    }

class bar{
    constructor(){
        this.property = 'no';
    }

    fire(callback){
        let value = 'message';
        callback(value);
    }
}

let object = new foo();
object.eventMethod();

this doesn’t work obviously because “this” now no longer referes to the foo created object.
I’m planning on using the controller from the foo class and the popup menu created by the bar class a lot. Therefore I’m using classes instead of creating single objects.

My question is if there is a way to deliver and process the values while still being able to do so within classes instead of objects because i want to use them multiple times.