17 lines
499 B
JavaScript
17 lines
499 B
JavaScript
chrome.runtime.onInstalled.addListener(() => {
|
|
chrome.contextMenus.create({
|
|
id: 'send-to-recipe-manager',
|
|
title: 'Send to Recipe Manager',
|
|
contexts: ['page']
|
|
});
|
|
});
|
|
|
|
chrome.contextMenus.onClicked.addListener((info, tab) => {
|
|
if (info.menuItemId !== 'send-to-recipe-manager' || !tab?.url) {
|
|
return;
|
|
}
|
|
|
|
// Placeholder for task: "Add 'Send to Recipe Manager' action to call import API"
|
|
console.info('[Recipe Manager Extension] Context menu clicked for URL:', tab.url);
|
|
});
|