@osovitny/anatoly 3.20.29 → 3.20.31

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.
@@ -378,6 +378,15 @@ class AppContextService extends ApiServiceBase {
378
378
  this._standardJsonFilesLoaded = new BehaviorSubject(null);
379
379
  this.standardJsonFilesLoaded$ = this._standardJsonFilesLoaded.asObservable();
380
380
  this.baseUrl = `${ApiUrl}/app`;
381
+ this.internalInit();
382
+ }
383
+ internalInit() {
384
+ this.setDefaults();
385
+ this.setValues();
386
+ this.contextUpdated(this.current);
387
+ this.updated$.subscribe((context) => {
388
+ this.contextUpdated(context);
389
+ });
381
390
  }
382
391
  //fires
383
392
  fireUpdated(data) {
@@ -4931,6 +4940,22 @@ class PaymentOptionsComponent extends ComponentBase {
4931
4940
  */
4932
4941
  //Node
4933
4942
  class EditComponentBase extends ComponentBase {
4943
+ /**
4944
+ * returns formgroup controls.
4945
+ * main use case is used in html pages
4946
+ */
4947
+ get fc() {
4948
+ return this.formGroup.controls;
4949
+ }
4950
+ get isNgModelBased() {
4951
+ return !this.isFormBased;
4952
+ }
4953
+ get isFormBased() {
4954
+ if (this.controlName) {
4955
+ return true;
4956
+ }
4957
+ return false;
4958
+ }
4934
4959
  constructor() {
4935
4960
  super();
4936
4961
  //Modes
@@ -5025,16 +5050,6 @@ class EditComponentBase extends ComponentBase {
5025
5050
  let fg = frmGroup ? frmGroup : this.formGroup;
5026
5051
  fg.get(controlName)?.setErrors({ invalid: true });
5027
5052
  }
5028
- /**
5029
- * returns formgroup controls.
5030
- * main use case is used in html pages
5031
- */
5032
- get fc() {
5033
- return this.formGroup.controls;
5034
- }
5035
- get isNgModelBased() {
5036
- return this.controlName == null;
5037
- }
5038
5053
  static { this.ɵfac = function EditComponentBase_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || EditComponentBase)(); }; }
5039
5054
  static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: EditComponentBase, selectors: [["ng-component"]], inputs: { formGroup: "formGroup", formSubmitted: "formSubmitted", controlName: "controlName", controlTitle: "controlTitle" }, features: [i0.ɵɵInheritDefinitionFeature], decls: 0, vars: 0, template: function EditComponentBase_Template(rf, ctx) { }, encapsulation: 2 }); }
5040
5055
  }
@@ -6955,11 +6970,11 @@ class PagedPageBase extends PageBase {
6955
6970
  class ListBase extends ComponentBase {
6956
6971
  constructor() {
6957
6972
  super(...arguments);
6958
- this.currentFilter = null;
6959
- this.dataLoaded = false;
6973
+ this._currentFilter = null;
6960
6974
  this.totalItems = 0;
6961
6975
  this.skipItems = 0;
6962
6976
  this.currentPage = 1;
6977
+ this.dataLoaded = false;
6963
6978
  //Inputs
6964
6979
  this.pageSize = 10;
6965
6980
  this.autoDataLoading = false;
@@ -6967,6 +6982,9 @@ class ListBase extends ComponentBase {
6967
6982
  this.filterRequest = new EventEmitter();
6968
6983
  this.dataChange = new EventEmitter();
6969
6984
  }
6985
+ get currentFilter() {
6986
+ return this._currentFilter;
6987
+ }
6970
6988
  ngOnInit() {
6971
6989
  this.init();
6972
6990
  }
@@ -7000,7 +7018,7 @@ class ListBase extends ComponentBase {
7000
7018
  }
7001
7019
  setFilter(filter) {
7002
7020
  if (filter) {
7003
- this.currentFilter = filter;
7021
+ this._currentFilter = filter;
7004
7022
  this.loadPageOne();
7005
7023
  }
7006
7024
  }
@@ -7692,7 +7710,7 @@ class PublishStatusDropdownlist extends EnumEditComponentBase {
7692
7710
  }
7693
7711
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(PublishStatusDropdownlist, [{
7694
7712
  type: Component,
7695
- args: [{ selector: 'anatoly-publishstatus-dropdownlist', standalone: false, template: "<div *ngIf='isNgModelBased'>\r\n <kendo-label text=\"{{ title }}\" *ngIf='isTitleVisible'></kendo-label>\r\n <kendo-dropdownlist [data]=\"items\"\r\n valueField=\"value\" textField=\"text\"\r\n [valuePrimitive]=\"true\"\r\n [(ngModel)]=\"sv\"\r\n (valueChange)=\"onChange($event)\" />\r\n</div>\r\n\r\n<div *ngIf='!isNgModelBased' [formGroup]='formGroup'>\r\n <kendo-label text=\"{{ title }}\" *ngIf='isTitleVisible'></kendo-label>\r\n <kendo-dropdownlist [data]=\"items\"\r\n valueField=\"value\" textField=\"text\"\r\n [valuePrimitive]=\"true\"\r\n [formControlName]='controlName' />\r\n <anatoly-item-validation-summary [formGroup]='formGroup'\r\n [formSubmitted]='formSubmitted'\r\n [controlName]='controlName'\r\n [controlTitle]='controlTitle' />\r\n</div>\r\n" }]
7713
+ args: [{ selector: 'anatoly-publishstatus-dropdownlist', standalone: false, template: "<div *ngIf='isNgModelBased'>\r\n <kendo-label text=\"{{ title }}\" *ngIf='isTitleVisible'></kendo-label>\r\n <kendo-dropdownlist [data]=\"items\"\r\n valueField=\"value\" textField=\"text\"\r\n [valuePrimitive]=\"true\"\r\n [(ngModel)]=\"sv\"\r\n (valueChange)=\"onChange($event)\" />\r\n</div>\r\n\r\n<div *ngIf='!isNgModelBased' [formGroup]='formGroup'>\r\n <kendo-label text=\"{{ title }}\" *ngIf='isTitleVisible'></kendo-label>\r\n <kendo-dropdownlist [data]=\"items\"\r\n valueField=\"value\" textField=\"text\"\r\n [valuePrimitive]=\"true\"\r\n [formControlName]='controlName' />\r\n <anatoly-item-validation-summary [formGroup]='formGroup'\r\n [formSubmitted]='formSubmitted'\r\n [controlName]='controlName'\r\n [controlTitle]='controlTitle' />\r\n</div>\r\n" }]
7696
7714
  }], () => [], null); })();
7697
7715
  (() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(PublishStatusDropdownlist, { className: "PublishStatusDropdownlist", filePath: "lib/ui/components/dropdownlists/publishstatus/publishstatus.dropdownlist.ts", lineNumber: 28 }); })();
7698
7716
 
@@ -8041,8 +8059,6 @@ function HtmlEditorComponent_div_1_Template(rf, ctx) { if (rf & 1) {
8041
8059
  class HtmlEditorComponent extends HtmlEditorComponentBase {
8042
8060
  constructor() {
8043
8061
  super();
8044
- this.controlName = "html";
8045
- this.controlTitle = "Html";
8046
8062
  }
8047
8063
  getHtml() {
8048
8064
  let editor = this.getEditor();
@@ -8060,11 +8076,6 @@ class HtmlEditorComponent extends HtmlEditorComponentBase {
8060
8076
  editor.html.set(content);
8061
8077
  });
8062
8078
  }
8063
- setFormValueAfterInitialized(name, value) {
8064
- this.doAfterInitialized(function (that) {
8065
- that.setFormValue(name, value);
8066
- });
8067
- }
8068
8079
  static { this.ɵfac = function HtmlEditorComponent_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || HtmlEditorComponent)(); }; }
8069
8080
  static { this.ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: HtmlEditorComponent, selectors: [["anatoly-html-editor"]], standalone: false, features: [i0.ɵɵInheritDefinitionFeature], decls: 2, vars: 2, consts: [[4, "ngIf"], [3, "formGroup", 4, "ngIf"], [3, "text", 4, "ngIf"], [3, "froalaInit", "froalaEditor"], [3, "text"], [3, "formGroup"], [3, "froalaInit", "froalaEditor", "formControlName"], [3, "formGroup", "formSubmitted", "controlName", "controlTitle"]], template: function HtmlEditorComponent_Template(rf, ctx) { if (rf & 1) {
8070
8081
  i0.ɵɵtemplate(0, HtmlEditorComponent_div_0_Template, 3, 2, "div", 0)(1, HtmlEditorComponent_div_1_Template, 5, 9, "div", 1);