ngx-rs-ant 1.2.0 → 1.2.2

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.
@@ -3,7 +3,7 @@ import { Component, Input, HostBinding, EventEmitter, Output, HostListener, View
3
3
  import { PluginFactory } from 'coast-plugin-register';
4
4
  import * as i1 from '@angular/common';
5
5
  import { CommonModule } from '@angular/common';
6
- import { Subject, map, of, lastValueFrom, interval } from 'rxjs';
6
+ import { Subject, ReplaySubject, Subscription, map, of, lastValueFrom, interval } from 'rxjs';
7
7
  import * as i2 from 'devextreme-angular/ui/number-box';
8
8
  import * as i2$1 from 'devextreme-angular/ui/draggable';
9
9
  import { DevExtremeModule, DxDataGridComponent, DxValidationGroupComponent, DxLoadPanelModule } from 'devextreme-angular';
@@ -17,10 +17,10 @@ import * as i5 from 'devextreme-angular/ui/tooltip';
17
17
  import * as i2$2 from '@angular/platform-browser';
18
18
  import * as i4 from 'devextreme-angular/ui/button';
19
19
  import * as i3$1 from 'devextreme-angular/ui/accordion';
20
- import * as i5$2 from 'devextreme-angular/ui/load-panel';
20
+ import * as i6 from 'devextreme-angular/ui/load-panel';
21
21
  import { __awaiter } from 'tslib';
22
22
  import notify from 'devextreme/ui/notify';
23
- import * as i6 from 'devextreme-angular/ui/validation-group';
23
+ import * as i7 from 'devextreme-angular/ui/validation-group';
24
24
  import * as i3$2 from 'devextreme-angular/ui/text-box';
25
25
  import * as i4$2 from 'devextreme-angular/ui/popover';
26
26
 
@@ -592,7 +592,7 @@ class BoxItemComponent {
592
592
  var _a, _b;
593
593
  const width = ((_a = item.style) === null || _a === void 0 ? void 0 : _a.width) ? item.style.width : 'auto';
594
594
  const height = ((_b = item.style) === null || _b === void 0 ? void 0 : _b.height) ? item.style.height : 'auto';
595
- return Object.assign(Object.assign({}, this._calcStyle(this.config.direction, width, height)), { overflow: 'auto' });
595
+ return this._calcStyle(this.config.direction, width, height);
596
596
  }
597
597
  _calcStyle(direction, width, height) {
598
598
  if (direction === 'row') {
@@ -673,6 +673,68 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImpor
673
673
  args: [BoxItemHostDirective]
674
674
  }] } });
675
675
 
676
+ class ChangeFilter {
677
+ constructor() {
678
+ this.subject = new ReplaySubject(1);
679
+ this.subscriptions = new Subscription();
680
+ }
681
+ doFilter(changes) {
682
+ this.subject.next(changes);
683
+ }
684
+ dispose() {
685
+ this.subscriptions.unsubscribe();
686
+ }
687
+ notEmpty(key, handler) {
688
+ this.subscriptions.add(this.subject.subscribe(changes => {
689
+ if (changes[key]) {
690
+ const value = changes[key].currentValue;
691
+ if (value !== undefined && value !== null) {
692
+ handler(value);
693
+ }
694
+ }
695
+ }));
696
+ }
697
+ has(key, handler) {
698
+ this.subscriptions.add(this.subject.subscribe(changes => {
699
+ if (changes[key]) {
700
+ const value = changes[key].currentValue;
701
+ handler(value);
702
+ }
703
+ }));
704
+ }
705
+ notFirst(key, handler) {
706
+ this.subscriptions.add(this.subject.subscribe(changes => {
707
+ if (changes[key] && !changes[key].isFirstChange()) {
708
+ const value = changes[key].currentValue;
709
+ handler(value);
710
+ }
711
+ }));
712
+ }
713
+ notFirstAndEmpty(key, handler) {
714
+ this.subscriptions.add(this.subject.subscribe(changes => {
715
+ if (changes[key] && !changes[key].isFirstChange()) {
716
+ const value = changes[key].currentValue;
717
+ if (value !== undefined && value !== null) {
718
+ handler(value);
719
+ }
720
+ }
721
+ }));
722
+ }
723
+ anyNotFirst(keys, handler) {
724
+ this.subscriptions.add(this.subject.subscribe(changes => {
725
+ let hasChange = false;
726
+ for (let key of keys) {
727
+ if (changes[key] && !changes[key].isFirstChange()) {
728
+ hasChange = true;
729
+ }
730
+ }
731
+ if (hasChange) {
732
+ handler();
733
+ }
734
+ }));
735
+ }
736
+ }
737
+
676
738
  class BoxContainerComponent {
677
739
  constructor() {
678
740
  this.editMode = false;
@@ -681,9 +743,23 @@ class BoxContainerComponent {
681
743
  list: [{ type: 'blank', style: {} }]
682
744
  };
683
745
  this.readonly = false;
746
+ this.changeFilter = new ChangeFilter();
684
747
  }
685
748
  ngOnInit() {
749
+ this.load();
750
+ this.changeFilter.anyNotFirst(['config', 'model', 'readonly'], () => {
751
+ this.load();
752
+ });
753
+ }
754
+ ngOnChanges(changes) {
755
+ this.changeFilter.doFilter(changes);
756
+ }
757
+ ngOnDestroy() {
758
+ this.changeFilter.dispose();
759
+ }
760
+ load() {
686
761
  var _a;
762
+ this.boxContainerContent.clear();
687
763
  const boxItemComponentRef = this.boxContainerContent.createComponent(BoxItemComponent);
688
764
  const instance = boxItemComponentRef.instance;
689
765
  instance.boxContainer = this;
@@ -703,7 +779,7 @@ class BoxContainerComponent {
703
779
  }
704
780
  }
705
781
  BoxContainerComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: BoxContainerComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
706
- BoxContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: BoxContainerComponent, selector: "rs-box-container", inputs: { config: "config", model: "model", readonly: "readonly" }, viewQueries: [{ propertyName: "boxContainerContent", first: true, predicate: ["boxContainerContent"], descendants: true, read: ViewContainerRef, static: true }], ngImport: i0, template: "<ng-container #boxContainerContent></ng-container>\n", styles: [":host{flex:1;position:relative;display:flex;flex-flow:row nowrap}\n"] });
782
+ BoxContainerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: BoxContainerComponent, selector: "rs-box-container", inputs: { config: "config", model: "model", readonly: "readonly" }, viewQueries: [{ propertyName: "boxContainerContent", first: true, predicate: ["boxContainerContent"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<ng-container #boxContainerContent></ng-container>\n", styles: [":host{flex:1;position:relative;display:flex;flex-flow:row nowrap}\n"] });
707
783
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: BoxContainerComponent, decorators: [{
708
784
  type: Component,
709
785
  args: [{ selector: 'rs-box-container', template: "<ng-container #boxContainerContent></ng-container>\n", styles: [":host{flex:1;position:relative;display:flex;flex-flow:row nowrap}\n"] }]
@@ -1887,14 +1963,27 @@ function validate_group(validationGroup) {
1887
1963
  }
1888
1964
 
1889
1965
  class FormComponent {
1890
- constructor(service) {
1966
+ constructor(viewContainerRef, service) {
1967
+ this.viewContainerRef = viewContainerRef;
1891
1968
  this.service = service;
1892
1969
  this.readonly = false;
1893
1970
  this.submitCallback = new EventEmitter();
1894
1971
  this.loading = false;
1895
- this.window = window;
1972
+ this.changeFilter = new ChangeFilter();
1896
1973
  }
1897
1974
  ngOnInit() {
1975
+ this.load();
1976
+ this.changeFilter.anyNotFirst(['tenant', 'className', 'oid', 'copyOid', 'template'], () => {
1977
+ this.load();
1978
+ });
1979
+ }
1980
+ ngOnChanges(changes) {
1981
+ this.changeFilter.doFilter(changes);
1982
+ }
1983
+ ngOnDestroy() {
1984
+ this.changeFilter.dispose();
1985
+ }
1986
+ load() {
1898
1987
  this.loading = true;
1899
1988
  this.service.getFormTemplateConfig(this.tenant, this.className, this.template).subscribe(response => {
1900
1989
  this.config = response.data.template;
@@ -1932,12 +2021,12 @@ class FormComponent {
1932
2021
  this.formSubmitter.instance.element().click();
1933
2022
  }
1934
2023
  }
1935
- FormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: FormComponent, deps: [{ token: FormService }], target: i0.ɵɵFactoryTarget.Component });
1936
- FormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: FormComponent, selector: "rs-form", inputs: { tenant: "tenant", className: "className", oid: "oid", copyOid: "copyOid", template: "template", readonly: "readonly" }, outputs: { submitCallback: "submitCallback" }, providers: [FormService], viewQueries: [{ propertyName: "validator", first: true, predicate: DxValidationGroupComponent, descendants: true }, { propertyName: "formSubmitter", first: true, predicate: ["formSubmitter"], descendants: true }], ngImport: i0, template: "<dx-load-panel [position]=\"{my: 'center', at: 'center', of: form.parentElement?.parentElement || window}\"\n [showPane]=\"false\"\n [visible]=\"!model\"></dx-load-panel>\n<form #form>\n <dx-validation-group *ngIf=\"model\">\n <rs-box-container [config]=\"config\" [model]=\"model\" [readonly]=\"readonly\"></rs-box-container>\n <dx-button #formSubmitter [visible]=\"false\" (onClick)=\"submitForm()\"></dx-button>\n </dx-validation-group>\n</form>\n", styles: [":host{padding:12px 24px 20px}:host form{display:flex;flex-flow:row nowrap}:host form dx-validation-group{width:100%}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BoxContainerComponent, selector: "rs-box-container", inputs: ["config", "model", "readonly"] }, { kind: "component", type: i4.DxButtonComponent, selector: "dx-button", inputs: ["accessKey", "activeStateEnabled", "disabled", "elementAttr", "focusStateEnabled", "height", "hint", "hoverStateEnabled", "icon", "rtlEnabled", "stylingMode", "tabIndex", "template", "text", "type", "useSubmitBehavior", "validationGroup", "visible", "width"], outputs: ["onClick", "onContentReady", "onDisposing", "onInitialized", "onOptionChanged", "accessKeyChange", "activeStateEnabledChange", "disabledChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hintChange", "hoverStateEnabledChange", "iconChange", "rtlEnabledChange", "stylingModeChange", "tabIndexChange", "templateChange", "textChange", "typeChange", "useSubmitBehaviorChange", "validationGroupChange", "visibleChange", "widthChange"] }, { kind: "component", type: i5$2.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: i6.DxValidationGroupComponent, selector: "dx-validation-group", inputs: ["elementAttr", "height", "width"], outputs: ["onDisposing", "onInitialized", "onOptionChanged", "elementAttrChange", "heightChange", "widthChange"] }] });
2024
+ FormComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: FormComponent, deps: [{ token: i0.ViewContainerRef }, { token: FormService }], target: i0.ɵɵFactoryTarget.Component });
2025
+ FormComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: FormComponent, selector: "rs-form", inputs: { tenant: "tenant", className: "className", oid: "oid", copyOid: "copyOid", template: "template", readonly: "readonly" }, outputs: { submitCallback: "submitCallback" }, providers: [FormService], viewQueries: [{ propertyName: "validator", first: true, predicate: DxValidationGroupComponent, descendants: true }, { propertyName: "formSubmitter", first: true, predicate: ["formSubmitter"], descendants: true }], usesOnChanges: true, ngImport: i0, template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<dx-validation-group *ngIf=\"!loading\">\n <rs-box-container [config]=\"config\" [model]=\"model\" [readonly]=\"readonly\"></rs-box-container>\n <dx-button #formSubmitter [visible]=\"false\" (onClick)=\"submitForm()\"></dx-button>\n</dx-validation-group>\n", styles: [":host{padding:12px 24px 20px}:host dx-validation-group{display:flex;flex-flow:row nowrap}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: BoxContainerComponent, selector: "rs-box-container", inputs: ["config", "model", "readonly"] }, { kind: "component", type: i5$1.DxoPositionComponent, selector: "dxo-position", inputs: ["at", "boundary", "boundaryOffset", "collision", "my", "of", "offset"] }, { kind: "component", type: i4.DxButtonComponent, selector: "dx-button", inputs: ["accessKey", "activeStateEnabled", "disabled", "elementAttr", "focusStateEnabled", "height", "hint", "hoverStateEnabled", "icon", "rtlEnabled", "stylingMode", "tabIndex", "template", "text", "type", "useSubmitBehavior", "validationGroup", "visible", "width"], outputs: ["onClick", "onContentReady", "onDisposing", "onInitialized", "onOptionChanged", "accessKeyChange", "activeStateEnabledChange", "disabledChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hintChange", "hoverStateEnabledChange", "iconChange", "rtlEnabledChange", "stylingModeChange", "tabIndexChange", "templateChange", "textChange", "typeChange", "useSubmitBehaviorChange", "validationGroupChange", "visibleChange", "widthChange"] }, { kind: "component", type: i6.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: i7.DxValidationGroupComponent, selector: "dx-validation-group", inputs: ["elementAttr", "height", "width"], outputs: ["onDisposing", "onInitialized", "onOptionChanged", "elementAttrChange", "heightChange", "widthChange"] }] });
1937
2026
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: FormComponent, decorators: [{
1938
2027
  type: Component,
1939
- args: [{ selector: 'rs-form', providers: [FormService], template: "<dx-load-panel [position]=\"{my: 'center', at: 'center', of: form.parentElement?.parentElement || window}\"\n [showPane]=\"false\"\n [visible]=\"!model\"></dx-load-panel>\n<form #form>\n <dx-validation-group *ngIf=\"model\">\n <rs-box-container [config]=\"config\" [model]=\"model\" [readonly]=\"readonly\"></rs-box-container>\n <dx-button #formSubmitter [visible]=\"false\" (onClick)=\"submitForm()\"></dx-button>\n </dx-validation-group>\n</form>\n", styles: [":host{padding:12px 24px 20px}:host form{display:flex;flex-flow:row nowrap}:host form dx-validation-group{width:100%}\n"] }]
1940
- }], ctorParameters: function () { return [{ type: FormService }]; }, propDecorators: { tenant: [{
2028
+ args: [{ selector: 'rs-form', providers: [FormService], template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<dx-validation-group *ngIf=\"!loading\">\n <rs-box-container [config]=\"config\" [model]=\"model\" [readonly]=\"readonly\"></rs-box-container>\n <dx-button #formSubmitter [visible]=\"false\" (onClick)=\"submitForm()\"></dx-button>\n</dx-validation-group>\n", styles: [":host{padding:12px 24px 20px}:host dx-validation-group{display:flex;flex-flow:row nowrap}\n"] }]
2029
+ }], ctorParameters: function () { return [{ type: i0.ViewContainerRef }, { type: FormService }]; }, propDecorators: { tenant: [{
1941
2030
  type: Input
1942
2031
  }], className: [{
1943
2032
  type: Input
@@ -1975,7 +2064,7 @@ class DataDetailComponent {
1975
2064
  }
1976
2065
  }
1977
2066
  DataDetailComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: DataDetailComponent, deps: [{ token: i0.ViewContainerRef }, { token: DataDetailService }], target: i0.ɵɵFactoryTarget.Component });
1978
- DataDetailComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: DataDetailComponent, selector: "coast-data-detail", inputs: { tenant: "tenant", className: "className", oid: "oid" }, providers: [DataDetailService], ngImport: i0, template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div *ngIf=\"!loading && sections.length === 0\" class=\"empty\">\n <span>\u60A8\u65E0\u6743\u67E5\u770B\u8BE5\u6570\u636E\u5B9E\u4F8B\u4EFB\u4F55\u4FE1\u606F</span>\n</div>\n<ng-container *ngIf=\"sections.length > 0\">\n <dx-accordion [collapsible]=\"true\" [multiple]=\"true\" [deferRendering]=\"false\" [dataSource]=\"sections\"\n [selectedItems]=\"sections\">\n <div *dxTemplate=\"let section of 'title'\" class=\"section-title\">\n <div class=\"section-title-name\">{{section.name}}</div>\n </div>\n <div *dxTemplate=\"let section of 'item'\">\n <rs-form [tenant]=\"tenant\" [className]=\"className\" [oid]=\"oid\" [template]=\"section.formTemplate\"\n [readonly]=\"true\"></rs-form>\n </div>\n </dx-accordion>\n</ng-container>\n", styles: [":host{flex:1;padding:24px;display:flex;flex-flow:column nowrap}:host div.empty{flex:1;padding:16px;display:flex;flex-flow:row nowrap;justify-content:center;align-items:center}:host div.empty span{text-align:center;-webkit-user-select:none;user-select:none}:host .section-title{border-bottom:1px solid var(--coast-border-color, #dddddd)}:host .section-title .section-title-name{height:24px;font-size:14px;font-weight:700;padding:4px 8px;display:flex;flex-flow:column nowrap;justify-content:center}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$1.DxAccordionComponent, selector: "dx-accordion", inputs: ["accessKey", "activeStateEnabled", "animationDuration", "collapsible", "dataSource", "deferRendering", "disabled", "elementAttr", "focusStateEnabled", "height", "hint", "hoverStateEnabled", "itemHoldTimeout", "items", "itemTemplate", "itemTitleTemplate", "keyExpr", "multiple", "noDataText", "repaintChangesOnly", "rtlEnabled", "selectedIndex", "selectedItem", "selectedItemKeys", "selectedItems", "tabIndex", "visible", "width"], outputs: ["onContentReady", "onDisposing", "onInitialized", "onItemClick", "onItemContextMenu", "onItemHold", "onItemRendered", "onItemTitleClick", "onOptionChanged", "onSelectionChanged", "accessKeyChange", "activeStateEnabledChange", "animationDurationChange", "collapsibleChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hintChange", "hoverStateEnabledChange", "itemHoldTimeoutChange", "itemsChange", "itemTemplateChange", "itemTitleTemplateChange", "keyExprChange", "multipleChange", "noDataTextChange", "repaintChangesOnlyChange", "rtlEnabledChange", "selectedIndexChange", "selectedItemChange", "selectedItemKeysChange", "selectedItemsChange", "tabIndexChange", "visibleChange", "widthChange"] }, { kind: "directive", type: i3.DxTemplateDirective, selector: "[dxTemplate]", inputs: ["dxTemplateOf"] }, { kind: "component", type: i5$1.DxoPositionComponent, selector: "dxo-position", inputs: ["at", "boundary", "boundaryOffset", "collision", "my", "of", "offset"] }, { kind: "component", type: i5$2.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: FormComponent, selector: "rs-form", inputs: ["tenant", "className", "oid", "copyOid", "template", "readonly"], outputs: ["submitCallback"] }] });
2067
+ DataDetailComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: DataDetailComponent, selector: "coast-data-detail", inputs: { tenant: "tenant", className: "className", oid: "oid" }, providers: [DataDetailService], ngImport: i0, template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div *ngIf=\"!loading && sections.length === 0\" class=\"empty\">\n <span>\u60A8\u65E0\u6743\u67E5\u770B\u8BE5\u6570\u636E\u5B9E\u4F8B\u4EFB\u4F55\u4FE1\u606F</span>\n</div>\n<ng-container *ngIf=\"sections.length > 0\">\n <dx-accordion [collapsible]=\"true\" [multiple]=\"true\" [deferRendering]=\"false\" [dataSource]=\"sections\"\n [selectedItems]=\"sections\">\n <div *dxTemplate=\"let section of 'title'\" class=\"section-title\">\n <div class=\"section-title-name\">{{section.name}}</div>\n </div>\n <div *dxTemplate=\"let section of 'item'\">\n <rs-form [tenant]=\"tenant\" [className]=\"className\" [oid]=\"oid\" [template]=\"section.formTemplate\"\n [readonly]=\"true\"></rs-form>\n </div>\n </dx-accordion>\n</ng-container>\n", styles: [":host{flex:1;padding:24px;display:flex;flex-flow:column nowrap}:host div.empty{flex:1;padding:16px;display:flex;flex-flow:row nowrap;justify-content:center;align-items:center}:host div.empty span{text-align:center;-webkit-user-select:none;user-select:none}:host .section-title{border-bottom:1px solid var(--coast-border-color, #dddddd)}:host .section-title .section-title-name{height:24px;font-size:14px;font-weight:700;padding:4px 8px;display:flex;flex-flow:column nowrap;justify-content:center}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i3$1.DxAccordionComponent, selector: "dx-accordion", inputs: ["accessKey", "activeStateEnabled", "animationDuration", "collapsible", "dataSource", "deferRendering", "disabled", "elementAttr", "focusStateEnabled", "height", "hint", "hoverStateEnabled", "itemHoldTimeout", "items", "itemTemplate", "itemTitleTemplate", "keyExpr", "multiple", "noDataText", "repaintChangesOnly", "rtlEnabled", "selectedIndex", "selectedItem", "selectedItemKeys", "selectedItems", "tabIndex", "visible", "width"], outputs: ["onContentReady", "onDisposing", "onInitialized", "onItemClick", "onItemContextMenu", "onItemHold", "onItemRendered", "onItemTitleClick", "onOptionChanged", "onSelectionChanged", "accessKeyChange", "activeStateEnabledChange", "animationDurationChange", "collapsibleChange", "dataSourceChange", "deferRenderingChange", "disabledChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hintChange", "hoverStateEnabledChange", "itemHoldTimeoutChange", "itemsChange", "itemTemplateChange", "itemTitleTemplateChange", "keyExprChange", "multipleChange", "noDataTextChange", "repaintChangesOnlyChange", "rtlEnabledChange", "selectedIndexChange", "selectedItemChange", "selectedItemKeysChange", "selectedItemsChange", "tabIndexChange", "visibleChange", "widthChange"] }, { kind: "directive", type: i3.DxTemplateDirective, selector: "[dxTemplate]", inputs: ["dxTemplateOf"] }, { kind: "component", type: i5$1.DxoPositionComponent, selector: "dxo-position", inputs: ["at", "boundary", "boundaryOffset", "collision", "my", "of", "offset"] }, { kind: "component", type: i6.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: FormComponent, selector: "rs-form", inputs: ["tenant", "className", "oid", "copyOid", "template", "readonly"], outputs: ["submitCallback"] }] });
1979
2068
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: DataDetailComponent, decorators: [{
1980
2069
  type: Component,
1981
2070
  args: [{ selector: 'coast-data-detail', providers: [DataDetailService], template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div *ngIf=\"!loading && sections.length === 0\" class=\"empty\">\n <span>\u60A8\u65E0\u6743\u67E5\u770B\u8BE5\u6570\u636E\u5B9E\u4F8B\u4EFB\u4F55\u4FE1\u606F</span>\n</div>\n<ng-container *ngIf=\"sections.length > 0\">\n <dx-accordion [collapsible]=\"true\" [multiple]=\"true\" [deferRendering]=\"false\" [dataSource]=\"sections\"\n [selectedItems]=\"sections\">\n <div *dxTemplate=\"let section of 'title'\" class=\"section-title\">\n <div class=\"section-title-name\">{{section.name}}</div>\n </div>\n <div *dxTemplate=\"let section of 'item'\">\n <rs-form [tenant]=\"tenant\" [className]=\"className\" [oid]=\"oid\" [template]=\"section.formTemplate\"\n [readonly]=\"true\"></rs-form>\n </div>\n </dx-accordion>\n</ng-container>\n", styles: [":host{flex:1;padding:24px;display:flex;flex-flow:column nowrap}:host div.empty{flex:1;padding:16px;display:flex;flex-flow:row nowrap;justify-content:center;align-items:center}:host div.empty span{text-align:center;-webkit-user-select:none;user-select:none}:host .section-title{border-bottom:1px solid var(--coast-border-color, #dddddd)}:host .section-title .section-title-name{height:24px;font-size:14px;font-weight:700;padding:4px 8px;display:flex;flex-flow:column nowrap;justify-content:center}\n"] }]
@@ -2237,8 +2326,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImpor
2237
2326
  }]
2238
2327
  }] });
2239
2328
 
2240
- let loadedMonaco = false;
2241
- let loadPromise;
2242
2329
  class JavaEditorComponent {
2243
2330
  set code(code) {
2244
2331
  var _a;
@@ -2256,32 +2343,17 @@ class JavaEditorComponent {
2256
2343
  this.loading = true;
2257
2344
  }
2258
2345
  ngOnInit() {
2259
- if (loadedMonaco) {
2260
- loadPromise.then(() => {
2346
+ const baseUrl = './assets/monaco-editor/min/vs';
2347
+ const loaderScript = document.createElement('script');
2348
+ loaderScript.type = 'text/javascript';
2349
+ loaderScript.src = `${baseUrl}/loader.js`;
2350
+ loaderScript.addEventListener('load', () => {
2351
+ window.require.config({ paths: { 'vs': `${baseUrl}` } });
2352
+ window.require([`vs/editor/editor.main`], () => {
2261
2353
  this.initMonaco();
2262
2354
  });
2263
- }
2264
- else {
2265
- loadedMonaco = true;
2266
- loadPromise = new Promise((resolve) => {
2267
- const baseUrl = './assets/monaco-editor/min/vs';
2268
- if (typeof (window.monaco) === 'object') {
2269
- resolve();
2270
- return;
2271
- }
2272
- const loaderScript = document.createElement('script');
2273
- loaderScript.type = 'text/javascript';
2274
- loaderScript.src = `${baseUrl}/loader.js`;
2275
- loaderScript.addEventListener('load', () => {
2276
- window.require.config({ paths: { 'vs': `${baseUrl}` } });
2277
- window.require([`vs/editor/editor.main`], () => {
2278
- this.initMonaco();
2279
- resolve();
2280
- });
2281
- });
2282
- document.body.appendChild(loaderScript);
2283
- });
2284
- }
2355
+ });
2356
+ document.body.appendChild(loaderScript);
2285
2357
  }
2286
2358
  initMonaco() {
2287
2359
  this._editor = monaco.editor.create(this.editorContainer.nativeElement, {
@@ -2300,7 +2372,7 @@ class JavaEditorComponent {
2300
2372
  }
2301
2373
  }
2302
2374
  JavaEditorComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: JavaEditorComponent, deps: [{ token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
2303
- JavaEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: JavaEditorComponent, selector: "rs-java-editor", inputs: { code: "code", consoleMessage: "consoleMessage" }, outputs: { codeChange: "codeChange", onContentReady: "onContentReady" }, viewQueries: [{ propertyName: "editorContainer", first: true, predicate: ["editorContainer"], descendants: true, static: true }], ngImport: i0, template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div class=\"editor-container\" #editorContainer></div>\n<div *ngIf=\"consoleMessage\" class=\"editor-console\">{{consoleMessage}}</div>\n", styles: [":host{display:flex;flex-flow:column nowrap}:host .editor-container{flex:1}:host .editor-console{flex:0 0 30px;padding:4px;border:1px solid var(--coast-border-color, #dddddd);background-color:var(--coast-empty-color, #d4d4d4)}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5$2.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: i5$1.DxoPositionComponent, selector: "dxo-position", inputs: ["at", "boundary", "boundaryOffset", "collision", "my", "of", "offset"] }] });
2375
+ JavaEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "15.2.7", type: JavaEditorComponent, selector: "rs-java-editor", inputs: { code: "code", consoleMessage: "consoleMessage" }, outputs: { codeChange: "codeChange", onContentReady: "onContentReady" }, viewQueries: [{ propertyName: "editorContainer", first: true, predicate: ["editorContainer"], descendants: true, static: true }], ngImport: i0, template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div class=\"editor-container\" #editorContainer></div>\n<div *ngIf=\"consoleMessage\" class=\"editor-console\">{{consoleMessage}}</div>\n", styles: [":host{display:flex;flex-flow:column nowrap}:host .editor-container{flex:1}:host .editor-console{flex:0 0 30px;padding:4px;border:1px solid var(--coast-border-color, #dddddd);background-color:var(--coast-empty-color, #d4d4d4)}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6.DxLoadPanelComponent, selector: "dx-load-panel", inputs: ["animation", "closeOnOutsideClick", "container", "copyRootClassesToWrapper", "deferRendering", "delay", "elementAttr", "focusStateEnabled", "height", "hideOnOutsideClick", "hideOnParentScroll", "hint", "hoverStateEnabled", "indicatorSrc", "maxHeight", "maxWidth", "message", "minHeight", "minWidth", "position", "rtlEnabled", "shading", "shadingColor", "showIndicator", "showPane", "visible", "width", "wrapperAttr"], outputs: ["onContentReady", "onDisposing", "onHidden", "onHiding", "onInitialized", "onOptionChanged", "onShowing", "onShown", "animationChange", "closeOnOutsideClickChange", "containerChange", "copyRootClassesToWrapperChange", "deferRenderingChange", "delayChange", "elementAttrChange", "focusStateEnabledChange", "heightChange", "hideOnOutsideClickChange", "hideOnParentScrollChange", "hintChange", "hoverStateEnabledChange", "indicatorSrcChange", "maxHeightChange", "maxWidthChange", "messageChange", "minHeightChange", "minWidthChange", "positionChange", "rtlEnabledChange", "shadingChange", "shadingColorChange", "showIndicatorChange", "showPaneChange", "visibleChange", "widthChange", "wrapperAttrChange"] }, { kind: "component", type: i5$1.DxoPositionComponent, selector: "dxo-position", inputs: ["at", "boundary", "boundaryOffset", "collision", "my", "of", "offset"] }] });
2304
2376
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImport: i0, type: JavaEditorComponent, decorators: [{
2305
2377
  type: Component,
2306
2378
  args: [{ selector: 'rs-java-editor', template: "<dx-load-panel [container]=\"viewContainerRef.element.nativeElement\" [showPane]=\"false\"\n [visible]=\"loading\">\n <dxo-position [of]=\"viewContainerRef.element.nativeElement\"></dxo-position>\n</dx-load-panel>\n<div class=\"editor-container\" #editorContainer></div>\n<div *ngIf=\"consoleMessage\" class=\"editor-console\">{{consoleMessage}}</div>\n", styles: [":host{display:flex;flex-flow:column nowrap}:host .editor-container{flex:1}:host .editor-console{flex:0 0 30px;padding:4px;border:1px solid var(--coast-border-color, #dddddd);background-color:var(--coast-empty-color, #d4d4d4)}\n"] }]
@@ -2695,5 +2767,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "15.2.7", ngImpor
2695
2767
  * Generated bundle index. Do not edit.
2696
2768
  */
2697
2769
 
2698
- export { BoxContainerComponent, BoxContainerModule, DataDetailComponent, DataDetailModule, DataGridComponent, DataGridFactory, DataGridModule, DataGridService, DrawerComponent, DrawerModule, DrawerService, DynamicParamsComponent, DynamicParamsModule, FormComponent, FormModule, FormService, IconSelectorComponent, IconSelectorModule, InstanceLinkTemplateDirective, ItemConfigComponent, ItemStyleComponent, JavaEditorComponent, JavaEditorModule, MasterDetailTemplateDirective, ModalComponent, ModalModule, ModalService, PluginManager, RowButtonsTemplateDirective, WebsocketModule, WebsocketService, notify_error, notify_success, notify_warning, validate, validate_group };
2770
+ export { BoxContainerComponent, BoxContainerModule, ChangeFilter, DataDetailComponent, DataDetailModule, DataGridComponent, DataGridFactory, DataGridModule, DataGridService, DrawerComponent, DrawerModule, DrawerService, DynamicParamsComponent, DynamicParamsModule, FormComponent, FormModule, FormService, IconSelectorComponent, IconSelectorModule, InstanceLinkTemplateDirective, ItemConfigComponent, ItemStyleComponent, JavaEditorComponent, JavaEditorModule, MasterDetailTemplateDirective, ModalComponent, ModalModule, ModalService, PluginManager, RowButtonsTemplateDirective, WebsocketModule, WebsocketService, notify_error, notify_success, notify_warning, validate, validate_group };
2699
2771
  //# sourceMappingURL=ngx-rs-ant.mjs.map