@shopify/app-bridge-core
Version:
**[Join our team and work on libraries like this one.](https://www.shopify.ca/careers)**
11 lines (8 loc) • 375 B
JavaScript
import { Action } from './ButtonGroup/index.js';
function getGroupedButton(action, button, subgroups, updateCb) {
action.addChild(button, action.group, subgroups);
const { id, label, disabled, buttons, plain } = button;
action.subscribeToChild(button, Action.UPDATE, updateCb);
return { id, label, buttons, disabled, plain };
}
export { getGroupedButton };