Open ghost opened 5 years ago
The picker can be loaded in any iframe element within a page, so I may need more details on what you're trying to implement.
The picker has several configurable settings we set via query parameters in the URL. This typically controls what kind of content the picker can return. Regarding callbacks, when an image / content is selected, the picker sends a parent POST message that contains information about that CONTENT or ASSET.
The picker also sends additional parent POST messages that we use as callbacks inside of WCH but if the picker is loaded outside of WCH these are disabled by default. You can enable them by adding sendCustomEvents=true
as a query param to your request for the picker. The only events we send at this time are:
assetLicensingInProgress
: this message is fired when an asset begins licensing inside of the picker.
assetLicensingCompleted
: this message is fired when an asset completes licensing or runs into an error
close
: this message is fired when the user presses his ESC key when inside of the picker (which should close the picker if the parent frame is listening for this message)
Can the picker palette be launched outside of the iFrame generated when using the element custom UI. Alternatively, can the built-in picker palette to WCH be called using parameters including a call-back.