Skip to content

Commit

Permalink
SPLAT-1442 add image source for location
Browse files Browse the repository at this point in the history
  • Loading branch information
amalija-ramljak committed Sep 17, 2024
1 parent 83749e8 commit 14cb815
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,10 @@ const createLocation = ({ editor, model, selectedImage }) => {

fetch(createLocationEndpoint, {
method: 'POST',
body: JSON.stringify(selectedImage),
body: JSON.stringify({
...selectedImage,
source: editor.config.get(pluginKey).source
}),
})
.then(response => response.json())
.then(({ locationId }) => {
Expand Down
2 changes: 2 additions & 0 deletions bundle/Resources/public/js/ckeditor-plugin/plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ const NetgenRemoteMediaPlugin = (editor) => {
config: null,
/** Variation group for view */
variationGroup: null,
/** Source for remote resource locations */
source: null,
/** Endpoints for handling resources */
endpoints: defaultValue.endpoints,
});
Expand Down

0 comments on commit 14cb815

Please sign in to comment.