I am not sure if this problem is appropriate here, but I am building a survey in Qulatrics and Right now, in Qualtrics we can trigger a survey that is linked to a specific page load. I want to trigger a survey using link calls with a modal within a single-page application (SPA), specifically when a confirmation pop-up appears. Right now the pop-up window (modal) is on an already loaded page and not a separate page load itself which is usually where all the intercepts are triggered off. Which makes it hard to connect the intercept with this pop up as I am not aware of a way to trigger survey based on this pop-up window. Does anyone know if I can integrate a functionality in the SPA using link calls (JavaScript events) to trigger the display of survey or intercept based on this popup modal instead of a page load.
This is what i tried so far.
identify modal window which is an event listener "confirmation-modal-shown" I need help with the javascript and placement part.
javascript // Qualtrics API call to trigger a survey Qualtrics.SurveyEngine.addOnload(function() { Qualtrics.SurveyEngine.setEmbeddedData('customField', 'customValue'); // Set any custom data if needed }); Qualtrics.SurveyEngine.displaySurveys();