"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
function default_1(RED) {
    function MatterDeviceControlNode(config) {
        const node = this;
        RED.nodes.createNode(node, config);
        const matterDeviceNode = RED.nodes.getNode(config.device);
        node.on('input', (msg) => {
            const payload = msg.payload;
            matterDeviceNode.emit('change_status', payload);
        });
    }
    RED.nodes.registerType('matter-device-control', MatterDeviceControlNode);
}
exports.default = default_1;
