Node-Red configuration
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

ui_ui_control.html 1.5KB

1234567891011121314151617181920212223242526272829303132333435363738
  1. <script type="text/javascript">
  2. // convert to i18 text
  3. function c_(x) {
  4. return RED._("node-red-dashboard/ui_ui_control:ui_ui_control."+x);
  5. }
  6. RED.nodes.registerType('ui_ui_control', {
  7. category: RED._("node-red-dashboard/ui_base:ui_base.label.category"),
  8. color: 'rgb( 63, 173, 181)',
  9. defaults: {
  10. name: {value:""},
  11. events: {value:"all"}
  12. },
  13. inputs:1,
  14. outputs:1,
  15. align: "right",
  16. icon: "ui_link.png",
  17. paletteLabel: 'ui control',
  18. label: function() { return this.name || "ui control"; },
  19. labelStyle: function() { return this.name?"node_label_italic":""; },
  20. outputLabels: function() { return this.events; },
  21. });
  22. </script>
  23. <script type="text/html" data-template-name="ui_ui_control">
  24. <div class="form-row">
  25. <label for="node-input-events"><i class="fa fa-sign-out"></i> Output</label>
  26. <select id="node-input-events" style="width:70%;">
  27. <option value="all">Connect, lost, change tab or group events</option>
  28. <option value="change">Change tab or group events only</option>
  29. <option value="connect">Connect event only</option>
  30. </select>
  31. </div>
  32. <div class="form-row">
  33. <label for="node-input-name"><i class="fa fa-tag"></i> <span data-i18n="ui_ui_control.label.name"></span></label>
  34. <input type="text" id="node-input-name" data-i18n="[placeholder]ui_ui_control.placeholder.name">
  35. </div>
  36. </script>