@osovitny/anatoly 3.20.43 → 3.20.45

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -9,7 +9,7 @@
9
9
  align-content: center;
10
10
  justify-content: center;
11
11
  overflow: auto;
12
- z-index: 2000;
12
+ z-index: 20000;
13
13
  background-color: rgba(0, 0, 0, 0.6);
14
14
  }
15
15
 
@@ -7021,6 +7021,18 @@ class EnumEditComponentBase extends EditComponentBase {
7021
7021
  //Outputs
7022
7022
  this.valueChange = new EventEmitter();
7023
7023
  }
7024
+ //Inputs
7025
+ get selectedValue() {
7026
+ return this.sv;
7027
+ }
7028
+ set selectedValue(value) {
7029
+ if (!value) {
7030
+ return;
7031
+ }
7032
+ if (value != this.sv) {
7033
+ this.sv = value;
7034
+ }
7035
+ }
7024
7036
  ngOnInit() {
7025
7037
  this.setDefaults();
7026
7038
  this.setValues();
@@ -7029,55 +7041,45 @@ class EnumEditComponentBase extends EditComponentBase {
7029
7041
  this.renderItems();
7030
7042
  }
7031
7043
  setValues() {
7032
- if (!this.selectedValue) {
7033
- this.reset();
7044
+ if (this.isNgModelBased) {
7045
+ if (!this.selectedValue) {
7046
+ this.selectedValue = this.defaultValue;
7047
+ }
7048
+ }
7049
+ else {
7050
+ let value = this.getFormValue(this.controlName);
7051
+ if (!value) {
7052
+ this.setFormValue(this.controlName, this.defaultValue);
7053
+ }
7034
7054
  }
7035
7055
  }
7036
7056
  fireValueChange(value) {
7037
7057
  this.valueChange.emit(value);
7038
7058
  }
7039
7059
  renderItems() {
7040
- let all = [];
7041
- let data = Convert.enumToArray(this.enumeration);
7060
+ let one = [];
7061
+ let two = Convert.enumToArray(this.enumeration, true);
7042
7062
  if (this.isNgModelBased) {
7043
- all = [{ value: -1, text: 'All' }];
7063
+ one = [{ value: -1, text: 'All' }];
7044
7064
  }
7045
7065
  this.items = [];
7046
- this.items = all.concat(data);
7047
- }
7048
- //Public
7049
- reset() {
7050
- this.selectedValue = this.defaultValue;
7066
+ this.items = one.concat(two);
7051
7067
  }
7052
7068
  //Events
7053
7069
  onChange(value) {
7054
7070
  this.fireValueChange(value);
7055
7071
  }
7056
- //Properties
7057
- get selectedValue() {
7058
- if (this.isNgModelBased) {
7059
- return this.sv;
7060
- }
7061
- let value = this.getFormValue(this.controlName);
7062
- return value;
7063
- }
7064
- set selectedValue(value) {
7065
- if (!value) {
7066
- return;
7067
- }
7068
- if (value != this.sv) {
7069
- this.sv = value;
7070
- }
7071
- }
7072
7072
  static { this.ɵfac = /*@__PURE__*/ (() => { let ɵEnumEditComponentBase_BaseFactory; return function EnumEditComponentBase_Factory(__ngFactoryType__) { return (ɵEnumEditComponentBase_BaseFactory || (ɵEnumEditComponentBase_BaseFactory = i0.ɵɵgetInheritedFactory(EnumEditComponentBase)))(__ngFactoryType__ || EnumEditComponentBase); }; })(); }
7073
- static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: EnumEditComponentBase, selectors: [["ng-component"]], inputs: { defaultValue: "defaultValue" }, outputs: { valueChange: "valueChange" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 0, vars: 0, template: function EnumEditComponentBase_Template(rf, ctx) { }, encapsulation: 2 }); }
7073
+ static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: EnumEditComponentBase, selectors: [["ng-component"]], inputs: { selectedValue: "selectedValue", defaultValue: "defaultValue" }, outputs: { valueChange: "valueChange" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 0, vars: 0, template: function EnumEditComponentBase_Template(rf, ctx) { }, encapsulation: 2 }); }
7074
7074
  }
7075
7075
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(EnumEditComponentBase, [{
7076
7076
  type: Component,
7077
7077
  args: [{
7078
7078
  template: ''
7079
7079
  }]
7080
- }], null, { defaultValue: [{
7080
+ }], null, { selectedValue: [{
7081
+ type: Input
7082
+ }], defaultValue: [{
7081
7083
  type: Input
7082
7084
  }], valueChange: [{
7083
7085
  type: Output
@@ -9073,10 +9075,10 @@ function Message2UserComponent_Conditional_0_Template(rf, ctx) { if (rf & 1) {
9073
9075
  i0.ɵɵconditional(!(ctx_r1.message == null ? null : ctx_r1.message.block) ? 20 : -1);
9074
9076
  } }
9075
9077
  class Message2UserComponent extends ComponentBase {
9076
- constructor(go, ns) {
9078
+ constructor(go, mus) {
9077
9079
  super();
9078
9080
  this.go = go;
9079
- this.ns = ns;
9081
+ this.mus = mus;
9080
9082
  this.show = false;
9081
9083
  }
9082
9084
  ngOnInit() {
@@ -9086,14 +9088,14 @@ class Message2UserComponent extends ComponentBase {
9086
9088
  setDefaults() {
9087
9089
  }
9088
9090
  setValues() {
9089
- this.subs.sink = this.ns.subscribe({
9091
+ this.subs.sink = this.mus.subscribe({
9090
9092
  next: (data) => {
9091
9093
  if (!data) {
9092
9094
  return;
9093
9095
  }
9094
9096
  this.show = true;
9095
9097
  this.message = data;
9096
- this.config = this.ns.getConfig(data.type);
9098
+ this.config = this.mus.getConfig(data.type);
9097
9099
  if (this.message?.timeout) {
9098
9100
  setTimeout(() => {
9099
9101
  this.show = false;
@@ -9105,7 +9107,7 @@ class Message2UserComponent extends ComponentBase {
9105
9107
  //Events
9106
9108
  onCloseAndBlock() {
9107
9109
  this.show = false;
9108
- if (this.message.go2dashboard) {
9110
+ if (this.config.go2dashboard) {
9109
9111
  this.go.dashboard();
9110
9112
  }
9111
9113
  else {