How to use the lively.bindings.signal function in lively

To help you get started, we’ve selected a few lively examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github LivelyKernel / lively.morphic / components / widgets.js View on Github external
trigger() {
    try {
      this.checked = !this.checked;
      signal(this, "toggle", this.checked);
    } catch (err) {
      var w = this.world();
      if (w) w.logError(err);
      else console.error(err);
    }
  }
github LivelyKernel / lively.morphic / components / buttons.js View on Github external
trigger() {
    try {
      signal(this, "fire");
      typeof this.action == "function" && this.action();
    } catch (err) {
      var w = this.world();
      if (w) w.logError(err);
      else console.error(err);
    }
  }
github LivelyKernel / lively.morphic / components / widgets.js View on Github external
onChange(change) {
    super.onChange(change);
    let inputChange = change.selector === "replace",
        validInput = this.isFocused() && this.textString;
    if (this.get('placeholder icon')) this.get('placeholder icon').visible = !!this.textString;
    this.active && inputChange && signal(this, "searchInput", this.parseInput());
  }
github LivelyKernel / lively.morphic / ide / styling / style-popover.js View on Github external
toggle(value) {
    const [title] = this.submorphs,
          valueControl = this.toggledControl(value),
          submorphs = [title, ...(valueControl ? [valueControl] : [])];
    signal(this, "update", value && valueControl.value);
    if (valueControl) valueControl.opacity = 0;
    this.animate({submorphs, duration});
    if (valueControl) valueControl.animate({opacity: 1, duration});
  }

lively

Express-like AWS Lamba framework

Apache-2.0
Latest version published 9 years ago

Package Health Score

40 / 100
Full package analysis