@ng-nest/ui 20.1.7 → 20.2.1
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.
- package/auto-complete/index.d.ts +10 -2
- package/cascade/index.d.ts +2 -1
- package/checkbox/index.d.ts +1 -1
- package/collapse/index.d.ts +0 -3
- package/color-picker/index.d.ts +2 -1
- package/core/index.d.ts +3 -65
- package/date-picker/index.d.ts +20 -4
- package/dialog/index.d.ts +27 -11
- package/drawer/index.d.ts +10 -12
- package/dropdown/index.d.ts +2 -1
- package/fesm2022/ng-nest-ui-affix.mjs +11 -11
- package/fesm2022/ng-nest-ui-alert.mjs +13 -13
- package/fesm2022/ng-nest-ui-alert.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-anchor.mjs +18 -18
- package/fesm2022/ng-nest-ui-anchor.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-api.mjs +7 -7
- package/fesm2022/ng-nest-ui-api.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-attachments.mjs +18 -18
- package/fesm2022/ng-nest-ui-auto-complete.mjs +33 -26
- package/fesm2022/ng-nest-ui-auto-complete.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-avatar.mjs +18 -18
- package/fesm2022/ng-nest-ui-avatar.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-back-top.mjs +12 -12
- package/fesm2022/ng-nest-ui-back-top.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-badge.mjs +13 -13
- package/fesm2022/ng-nest-ui-badge.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-base-form.mjs +8 -8
- package/fesm2022/ng-nest-ui-bubble.mjs +20 -20
- package/fesm2022/ng-nest-ui-bubble.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-button.mjs +19 -19
- package/fesm2022/ng-nest-ui-button.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-calendar.mjs +11 -11
- package/fesm2022/ng-nest-ui-card.mjs +11 -11
- package/fesm2022/ng-nest-ui-carousel.mjs +21 -21
- package/fesm2022/ng-nest-ui-carousel.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-cascade.mjs +27 -25
- package/fesm2022/ng-nest-ui-cascade.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-checkbox.mjs +12 -12
- package/fesm2022/ng-nest-ui-checkbox.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-collapse.mjs +20 -28
- package/fesm2022/ng-nest-ui-collapse.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-color-picker.mjs +31 -29
- package/fesm2022/ng-nest-ui-color-picker.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-color.mjs +11 -11
- package/fesm2022/ng-nest-ui-color.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-comment.mjs +18 -18
- package/fesm2022/ng-nest-ui-container.mjs +35 -35
- package/fesm2022/ng-nest-ui-container.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-core.mjs +20 -348
- package/fesm2022/ng-nest-ui-core.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-coversations.mjs +11 -11
- package/fesm2022/ng-nest-ui-crumb.mjs +11 -11
- package/fesm2022/ng-nest-ui-date-picker.mjs +92 -78
- package/fesm2022/ng-nest-ui-date-picker.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-description.mjs +20 -20
- package/fesm2022/ng-nest-ui-description.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-dialog.mjs +122 -73
- package/fesm2022/ng-nest-ui-dialog.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-doc.mjs +7 -7
- package/fesm2022/ng-nest-ui-doc.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-drag.mjs +11 -11
- package/fesm2022/ng-nest-ui-drawer.mjs +67 -84
- package/fesm2022/ng-nest-ui-drawer.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-dropdown.mjs +27 -25
- package/fesm2022/ng-nest-ui-dropdown.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-empty.mjs +11 -11
- package/fesm2022/ng-nest-ui-examples.mjs +7 -7
- package/fesm2022/ng-nest-ui-examples.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-find.mjs +12 -12
- package/fesm2022/ng-nest-ui-find.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-form.mjs +19 -19
- package/fesm2022/ng-nest-ui-form.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-highlight.mjs +15 -15
- package/fesm2022/ng-nest-ui-highlight.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-i18n.mjs +14 -14
- package/fesm2022/ng-nest-ui-icon.mjs +14 -14
- package/fesm2022/ng-nest-ui-icon.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-image.mjs +21 -21
- package/fesm2022/ng-nest-ui-image.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-inner.mjs +11 -11
- package/fesm2022/ng-nest-ui-inner.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-input-number.mjs +12 -12
- package/fesm2022/ng-nest-ui-input-number.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-input.mjs +19 -19
- package/fesm2022/ng-nest-ui-input.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-keyword.mjs +11 -11
- package/fesm2022/ng-nest-ui-keyword.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-layout.mjs +18 -18
- package/fesm2022/ng-nest-ui-layout.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-link.mjs +12 -12
- package/fesm2022/ng-nest-ui-link.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-list.mjs +23 -23
- package/fesm2022/ng-nest-ui-list.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-loading.mjs +12 -12
- package/fesm2022/ng-nest-ui-loading.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-menu.mjs +18 -18
- package/fesm2022/ng-nest-ui-message-box.mjs +33 -20
- package/fesm2022/ng-nest-ui-message-box.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-message.mjs +13 -13
- package/fesm2022/ng-nest-ui-message.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-notification.mjs +13 -13
- package/fesm2022/ng-nest-ui-notification.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-outlet.mjs +8 -8
- package/fesm2022/ng-nest-ui-page-header.mjs +11 -11
- package/fesm2022/ng-nest-ui-pagination.mjs +11 -11
- package/fesm2022/ng-nest-ui-pagination.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-pattern.mjs +7 -7
- package/fesm2022/ng-nest-ui-pattern.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-popconfirm.mjs +11 -11
- package/fesm2022/ng-nest-ui-popover.mjs +25 -21
- package/fesm2022/ng-nest-ui-popover.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-portal.mjs +7 -7
- package/fesm2022/ng-nest-ui-progress.mjs +11 -11
- package/fesm2022/ng-nest-ui-prompts.mjs +11 -11
- package/fesm2022/ng-nest-ui-radio.mjs +12 -12
- package/fesm2022/ng-nest-ui-radio.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-rate.mjs +12 -12
- package/fesm2022/ng-nest-ui-rate.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-resizable.mjs +11 -11
- package/fesm2022/ng-nest-ui-resizable.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-result.mjs +11 -11
- package/fesm2022/ng-nest-ui-ripple.mjs +11 -11
- package/fesm2022/ng-nest-ui-ripple.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-scrollable.mjs +8 -8
- package/fesm2022/ng-nest-ui-scrollable.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-select.mjs +34 -26
- package/fesm2022/ng-nest-ui-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-sender.mjs +15 -15
- package/fesm2022/ng-nest-ui-sender.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-skeleton.mjs +11 -11
- package/fesm2022/ng-nest-ui-slider-select.mjs +13 -13
- package/fesm2022/ng-nest-ui-slider-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-slider.mjs +12 -12
- package/fesm2022/ng-nest-ui-slider.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-statistic.mjs +18 -18
- package/fesm2022/ng-nest-ui-steps.mjs +11 -11
- package/fesm2022/ng-nest-ui-suggestion.mjs +11 -11
- package/fesm2022/ng-nest-ui-switch.mjs +12 -12
- package/fesm2022/ng-nest-ui-switch.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-table-view.mjs +60 -60
- package/fesm2022/ng-nest-ui-table-view.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-table.mjs +60 -49
- package/fesm2022/ng-nest-ui-table.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tabs.mjs +30 -30
- package/fesm2022/ng-nest-ui-tabs.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tag.mjs +29 -19
- package/fesm2022/ng-nest-ui-tag.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-text-retract.mjs +11 -11
- package/fesm2022/ng-nest-ui-textarea.mjs +12 -12
- package/fesm2022/ng-nest-ui-textarea.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-theme.mjs +11 -11
- package/fesm2022/ng-nest-ui-thought-chain.mjs +11 -11
- package/fesm2022/ng-nest-ui-time-ago.mjs +7 -7
- package/fesm2022/ng-nest-ui-time-picker.mjs +31 -29
- package/fesm2022/ng-nest-ui-time-picker.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-time-range.mjs +7 -7
- package/fesm2022/ng-nest-ui-timeline.mjs +11 -11
- package/fesm2022/ng-nest-ui-tooltip.mjs +27 -74
- package/fesm2022/ng-nest-ui-tooltip.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-transfer.mjs +12 -12
- package/fesm2022/ng-nest-ui-transfer.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tree-file.mjs +11 -11
- package/fesm2022/ng-nest-ui-tree-select.mjs +27 -25
- package/fesm2022/ng-nest-ui-tree-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tree.mjs +23 -23
- package/fesm2022/ng-nest-ui-tree.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-typography.mjs +11 -11
- package/fesm2022/ng-nest-ui-upload.mjs +31 -28
- package/fesm2022/ng-nest-ui-upload.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-welcome.mjs +11 -11
- package/message/index.d.ts +1 -3
- package/message-box/index.d.ts +4 -3
- package/notification/index.d.ts +1 -3
- package/package.json +52 -52
- package/popover/index.d.ts +2 -1
- package/radio/index.d.ts +1 -1
- package/select/index.d.ts +11 -2
- package/style/animates/base.scss +32 -0
- package/style/animates/conect.scss +32 -0
- package/style/animates/fade.scss +32 -0
- package/style/animates/index.scss +11 -0
- package/style/animates/move.scss +129 -0
- package/style/animates/opacity.scss +26 -0
- package/style/animates/slide.scss +113 -0
- package/style/core/index.css +353 -0
- package/style/core/index.css.map +1 -1
- package/style/core/index.scss +1 -6
- package/table/index.d.ts +15 -4
- package/table-view/index.d.ts +1 -1
- package/tag/index.d.ts +6 -1
- package/time-picker/index.d.ts +2 -1
- package/tooltip/index.d.ts +2 -12
- package/tree-select/index.d.ts +2 -1
|
@@ -25,13 +25,13 @@ class XTypographyProperty extends XProperty {
|
|
|
25
25
|
*/
|
|
26
26
|
this.text = input(...(ngDevMode ? [undefined, { debugName: "text" }] : []));
|
|
27
27
|
}
|
|
28
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
29
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.
|
|
28
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
29
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.5", type: XTypographyProperty, isStandalone: true, selector: "x-typography-property", inputs: { font: { classPropertyName: "font", publicName: "font", isSignal: true, isRequired: false, transformFunction: null }, text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
|
|
30
30
|
}
|
|
31
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
31
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyProperty, decorators: [{
|
|
32
32
|
type: Component,
|
|
33
33
|
args: [{ selector: `${XTypographyPrefix}-property`, template: '' }]
|
|
34
|
-
}] });
|
|
34
|
+
}], propDecorators: { font: [{ type: i0.Input, args: [{ isSignal: true, alias: "font", required: false }] }], text: [{ type: i0.Input, args: [{ isSignal: true, alias: "text", required: false }] }] } });
|
|
35
35
|
|
|
36
36
|
class XTypographyComponent extends XTypographyProperty {
|
|
37
37
|
constructor() {
|
|
@@ -49,20 +49,20 @@ class XTypographyComponent extends XTypographyProperty {
|
|
|
49
49
|
if (text && text.length > 0)
|
|
50
50
|
this.firstText.set(text.slice(0, 1));
|
|
51
51
|
}
|
|
52
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
53
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.
|
|
52
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
53
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.5", type: XTypographyComponent, isStandalone: true, selector: "x-typography", usesInheritance: true, ngImport: i0, template: "<h4>{{ font() }}</h4>\r\n<div class=\"x-typography-list\">\r\n <div class=\"x-typography-item\">\r\n <h1>{{ firstText() }}</h1>\r\n <p>\r\n <span>\u5E38\u89C4</span>\r\n <span class=\"x-typography-blod\">\u7C97\u4F53</span>\r\n </p>\r\n </div>\r\n <div class=\"x-typography-item\">\r\n <h1>Aa</h1>\r\n <p>\r\n <span>Regular</span>\r\n <span class=\"x-typography-blod\">Bold</span>\r\n </p>\r\n </div>\r\n</div>\r\n<p>{{ text() }}</p>\r\n<p>abcdefghijklmnopqrstuvwxyz</p>\r\n<p>ABCDEFGHIJKLMNOPQRSTUVWXYZ</p>\r\n<p>1234567890.:,;'\"(!?)+-*/=</p>\r\n", styles: [".x-typography{margin:0;padding:0}.x-typography{color:var(--x-text)}.x-typography h4,.x-typography h1,.x-typography p{margin:0;font-size:var(--x-font-size);line-height:1.5rem}.x-typography>h4{color:var(--x-text-300);font-weight:500}.x-typography-list{display:flex;margin:.5rem 0}.x-typography-item{display:flex;margin:.5rem 0 0 3rem}.x-typography-item:first-child{margin-left:0}.x-typography-item>h1{color:var(--x-text);font-size:3.75rem;font-weight:600}.x-typography-item>p{display:flex;flex-direction:column;padding:.75rem 0;margin-left:1.5rem}.x-typography-item>p>span{margin-top:.25rem}.x-typography-item>p>span:first-child{margin-top:0}.x-typography-blod{font-weight:600}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
54
54
|
}
|
|
55
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
55
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyComponent, decorators: [{
|
|
56
56
|
type: Component,
|
|
57
57
|
args: [{ selector: 'x-typography', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<h4>{{ font() }}</h4>\r\n<div class=\"x-typography-list\">\r\n <div class=\"x-typography-item\">\r\n <h1>{{ firstText() }}</h1>\r\n <p>\r\n <span>\u5E38\u89C4</span>\r\n <span class=\"x-typography-blod\">\u7C97\u4F53</span>\r\n </p>\r\n </div>\r\n <div class=\"x-typography-item\">\r\n <h1>Aa</h1>\r\n <p>\r\n <span>Regular</span>\r\n <span class=\"x-typography-blod\">Bold</span>\r\n </p>\r\n </div>\r\n</div>\r\n<p>{{ text() }}</p>\r\n<p>abcdefghijklmnopqrstuvwxyz</p>\r\n<p>ABCDEFGHIJKLMNOPQRSTUVWXYZ</p>\r\n<p>1234567890.:,;'\"(!?)+-*/=</p>\r\n", styles: [".x-typography{margin:0;padding:0}.x-typography{color:var(--x-text)}.x-typography h4,.x-typography h1,.x-typography p{margin:0;font-size:var(--x-font-size);line-height:1.5rem}.x-typography>h4{color:var(--x-text-300);font-weight:500}.x-typography-list{display:flex;margin:.5rem 0}.x-typography-item{display:flex;margin:.5rem 0 0 3rem}.x-typography-item:first-child{margin-left:0}.x-typography-item>h1{color:var(--x-text);font-size:3.75rem;font-weight:600}.x-typography-item>p{display:flex;flex-direction:column;padding:.75rem 0;margin-left:1.5rem}.x-typography-item>p>span{margin-top:.25rem}.x-typography-item>p>span:first-child{margin-top:0}.x-typography-blod{font-weight:600}\n"] }]
|
|
58
58
|
}] });
|
|
59
59
|
|
|
60
60
|
class XTypographyModule {
|
|
61
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
62
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.
|
|
63
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.
|
|
61
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
62
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XTypographyModule, imports: [XTypographyComponent], exports: [XTypographyComponent] }); }
|
|
63
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyModule }); }
|
|
64
64
|
}
|
|
65
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
65
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XTypographyModule, decorators: [{
|
|
66
66
|
type: NgModule,
|
|
67
67
|
args: [{
|
|
68
68
|
exports: [XTypographyComponent],
|
|
@@ -141,13 +141,13 @@ class XUploadProperty extends XFormControlFunction(X_UPLOAD_CONFIG_NAME) {
|
|
|
141
141
|
*/
|
|
142
142
|
this.uploadError = output();
|
|
143
143
|
}
|
|
144
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
145
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.
|
|
144
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
145
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.5", type: XUploadProperty, isStandalone: true, selector: "x-upload-property", inputs: { text: { classPropertyName: "text", publicName: "text", isSignal: true, isRequired: false, transformFunction: null }, action: { classPropertyName: "action", publicName: "action", isSignal: true, isRequired: false, transformFunction: null }, dropContainer: { classPropertyName: "dropContainer", publicName: "dropContainer", isSignal: true, isRequired: false, transformFunction: null }, dropIcon: { classPropertyName: "dropIcon", publicName: "dropIcon", isSignal: true, isRequired: false, transformFunction: null }, dropTitle: { classPropertyName: "dropTitle", publicName: "dropTitle", isSignal: true, isRequired: false, transformFunction: null }, dropDescription: { classPropertyName: "dropDescription", publicName: "dropDescription", isSignal: true, isRequired: false, transformFunction: null }, showDrop: { classPropertyName: "showDrop", publicName: "showDrop", isSignal: true, isRequired: false, transformFunction: null }, accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, imgFallback: { classPropertyName: "imgFallback", publicName: "imgFallback", isSignal: true, isRequired: false, transformFunction: null }, imgCut: { classPropertyName: "imgCut", publicName: "imgCut", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, download: { classPropertyName: "download", publicName: "download", isSignal: true, isRequired: false, transformFunction: null }, multipleModel: { classPropertyName: "multipleModel", publicName: "multipleModel", isSignal: true, isRequired: false, transformFunction: null }, filesTpl: { classPropertyName: "filesTpl", publicName: "filesTpl", isSignal: true, isRequired: false, transformFunction: null }, maxLimit: { classPropertyName: "maxLimit", publicName: "maxLimit", isSignal: true, isRequired: false, transformFunction: null }, headers: { classPropertyName: "headers", publicName: "headers", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { removeClick: "removeClick", uploadReady: "uploadReady", uploading: "uploading", uploadSuccess: "uploadSuccess", uploadError: "uploadError" }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
|
|
146
146
|
}
|
|
147
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
147
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadProperty, decorators: [{
|
|
148
148
|
type: Component,
|
|
149
149
|
args: [{ selector: `${XUploadPrefix}-property`, template: '' }]
|
|
150
|
-
}] });
|
|
150
|
+
}], propDecorators: { text: [{ type: i0.Input, args: [{ isSignal: true, alias: "text", required: false }] }], action: [{ type: i0.Input, args: [{ isSignal: true, alias: "action", required: false }] }], dropContainer: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropContainer", required: false }] }], dropIcon: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropIcon", required: false }] }], dropTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropTitle", required: false }] }], dropDescription: [{ type: i0.Input, args: [{ isSignal: true, alias: "dropDescription", required: false }] }], showDrop: [{ type: i0.Input, args: [{ isSignal: true, alias: "showDrop", required: false }] }], accept: [{ type: i0.Input, args: [{ isSignal: true, alias: "accept", required: false }] }], type: [{ type: i0.Input, args: [{ isSignal: true, alias: "type", required: false }] }], imgFallback: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgFallback", required: false }] }], imgCut: [{ type: i0.Input, args: [{ isSignal: true, alias: "imgCut", required: false }] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], download: [{ type: i0.Input, args: [{ isSignal: true, alias: "download", required: false }] }], multipleModel: [{ type: i0.Input, args: [{ isSignal: true, alias: "multipleModel", required: false }] }], filesTpl: [{ type: i0.Input, args: [{ isSignal: true, alias: "filesTpl", required: false }] }], maxLimit: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxLimit", required: false }] }], headers: [{ type: i0.Input, args: [{ isSignal: true, alias: "headers", required: false }] }], removeClick: [{ type: i0.Output, args: ["removeClick"] }], uploadReady: [{ type: i0.Output, args: ["uploadReady"] }], uploading: [{ type: i0.Output, args: ["uploading"] }], uploadSuccess: [{ type: i0.Output, args: ["uploadSuccess"] }], uploadError: [{ type: i0.Output, args: ["uploadError"] }] } });
|
|
151
151
|
/**
|
|
152
152
|
* @zh_CN 上传显示窗口
|
|
153
153
|
* @en_US Upload portal
|
|
@@ -336,13 +336,13 @@ class XUploadPortalComponent {
|
|
|
336
336
|
});
|
|
337
337
|
};
|
|
338
338
|
}
|
|
339
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
340
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "20.3.
|
|
339
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadPortalComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
340
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.2.0", version: "20.3.5", type: XUploadPortalComponent, isStandalone: true, selector: "x-upload-portal", inputs: { file: { classPropertyName: "file", publicName: "file", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { closePortal: "closePortal", surePortal: "surePortal" }, viewQueries: [{ propertyName: "imgRef", first: true, predicate: ["imgRef"], descendants: true, isSignal: true }, { propertyName: "imgClipRef", first: true, predicate: ["imgClipRef"], descendants: true, isSignal: true }, { propertyName: "boundaryRef", first: true, predicate: ["boundaryRef"], descendants: true, isSignal: true }, { propertyName: "cutRef", first: true, predicate: ["cutRef"], descendants: true, isSignal: true }], ngImport: i0, template: "<div class=\"x-upload-portal {{ cutType() }}\" [class.x-upload-portal-ready]=\"ready()\">\r\n <div class=\"x-upload-portal-tools\">\r\n <div class=\"x-upload-portal-title\">\r\n <x-icon type=\"fto-image\"></x-icon>\r\n <span>{{ name() }}</span>\r\n </div>\r\n <x-icon class=\"x-upload-portal-close\" type=\"fto-x\" (click)=\"closePortal.emit()\"></x-icon>\r\n </div>\r\n <div class=\"x-upload-portal-img\">\r\n <img #imgRef class=\"x-upload-portal-full-img\" [src]=\"url()\" />\r\n <div #boundaryRef class=\"x-upload-portal-boundary\">\r\n <img #imgClipRef class=\"x-upload-portal-clip-img\" [src]=\"url()\" />\r\n <div #cutRef class=\"x-upload-portal-cut\">\r\n <div class=\"x-upload-portal-cut-top-start\"></div>\r\n <div class=\"x-upload-portal-cut-top\"></div>\r\n <div class=\"x-upload-portal-cut-top-end\"></div>\r\n <div class=\"x-upload-portal-cut-left\"></div>\r\n <div class=\"x-upload-portal-cut-right\"></div>\r\n <div class=\"x-upload-portal-cut-bottom-start\"></div>\r\n <div class=\"x-upload-portal-cut-bottom\"></div>\r\n <div class=\"x-upload-portal-cut-bottom-end\"></div>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"x-upload-portal-bottom-tools\">\r\n <x-icon class=\"x-upload-portal-close\" type=\"fto-check\" (click)=\"sure()\"></x-icon>\r\n </div>\r\n</div>\r\n", styles: ["x-upload-portal{width:100%;height:100%}.x-upload-portal{margin:0;padding:0}.x-upload-portal{display:flex;position:relative;width:100%;height:100%;flex-direction:column}.x-upload-portal-tools{width:100%;height:3.25rem;display:flex;align-items:center;justify-content:space-between;position:absolute;z-index:1;color:#fff}.x-upload-portal-bottom-tools{width:100%;height:3.25rem;position:absolute;display:flex;justify-content:center;align-items:center;z-index:1;color:#fff;bottom:0}.x-upload-portal-title{display:flex;align-items:center;margin:0 1rem}.x-upload-portal-title>x-icon{font-size:1.25rem}.x-upload-portal-title>span{margin-left:.5rem}.x-upload-portal-close{font-size:1.75rem;padding:0 1rem;color:#fffc;transition:color var(--x-animation-duration-base);cursor:pointer}.x-upload-portal-close:hover{color:#fff}.x-upload-portal-img{flex:1;width:100%;position:relative;overflow:auto}.x-upload-portal-full-img{max-width:85%;max-height:85%;width:auto;height:auto;position:absolute;left:50%;top:50%;transform:translate3d(-50%,-50%,0)}.x-upload-portal-clip-img{position:absolute}.x-upload-portal-ready .x-upload-portal-full-img{max-width:inherit;max-height:inherit}.x-upload-portal-boundary{width:0;height:0;left:50%;top:50%;transform:translate3d(-50%,-50%,0);position:relative;background-color:#00000080}.x-upload-portal-cut{width:0;height:0;border:.125rem var(--x-border-style) rgba(255,255,255,.8);display:flex;align-items:center;justify-content:center;position:relative;cursor:move}.x-upload-portal-cut-top-start,.x-upload-portal-cut-top,.x-upload-portal-cut-top-end,.x-upload-portal-cut-left,.x-upload-portal-cut-right,.x-upload-portal-cut-bottom-start,.x-upload-portal-cut-bottom,.x-upload-portal-cut-bottom-end{width:.825rem;height:.825rem;background:#fff;position:absolute;border:var(--x-border-width) var(--x-border-style) var(--x-border);border-radius:var(--x-border-radius)}.x-upload-portal-cut-top-start{top:-.4125rem;left:-.4125rem;cursor:se-resize}.x-upload-portal-cut-top{top:-.4125rem;cursor:s-resize}.x-upload-portal-cut-top-end{top:-.4125rem;right:-.4125rem;cursor:ne-resize}.x-upload-portal-cut-left{left:-.4125rem;cursor:w-resize}.x-upload-portal-cut-right{right:-.4125rem;cursor:w-resize}.x-upload-portal-cut-bottom-start{left:-.4125rem;bottom:-.4125rem;cursor:ne-resize}.x-upload-portal-cut-bottom{bottom:-.4125rem;cursor:s-resize}.x-upload-portal-cut-bottom-end{right:-.4125rem;bottom:-.4125rem;cursor:se-resize}.x-upload-portal-top-start{cursor:se-resize}.x-upload-portal-top{cursor:s-resize}.x-upload-portal-top-end{cursor:ne-resize}.x-upload-portal-left,.x-upload-portal-right{cursor:w-resize}.x-upload-portal-bottom-start{cursor:ne-resize}.x-upload-portal-bottom{cursor:s-resize}.x-upload-portal-bottom-end{cursor:se-resize}\n"], dependencies: [{ kind: "component", type: XIconComponent, selector: "x-icon" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
341
341
|
}
|
|
342
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
342
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadPortalComponent, decorators: [{
|
|
343
343
|
type: Component,
|
|
344
344
|
args: [{ selector: `${XUploadPortalPrefix}`, imports: [XIconComponent], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"x-upload-portal {{ cutType() }}\" [class.x-upload-portal-ready]=\"ready()\">\r\n <div class=\"x-upload-portal-tools\">\r\n <div class=\"x-upload-portal-title\">\r\n <x-icon type=\"fto-image\"></x-icon>\r\n <span>{{ name() }}</span>\r\n </div>\r\n <x-icon class=\"x-upload-portal-close\" type=\"fto-x\" (click)=\"closePortal.emit()\"></x-icon>\r\n </div>\r\n <div class=\"x-upload-portal-img\">\r\n <img #imgRef class=\"x-upload-portal-full-img\" [src]=\"url()\" />\r\n <div #boundaryRef class=\"x-upload-portal-boundary\">\r\n <img #imgClipRef class=\"x-upload-portal-clip-img\" [src]=\"url()\" />\r\n <div #cutRef class=\"x-upload-portal-cut\">\r\n <div class=\"x-upload-portal-cut-top-start\"></div>\r\n <div class=\"x-upload-portal-cut-top\"></div>\r\n <div class=\"x-upload-portal-cut-top-end\"></div>\r\n <div class=\"x-upload-portal-cut-left\"></div>\r\n <div class=\"x-upload-portal-cut-right\"></div>\r\n <div class=\"x-upload-portal-cut-bottom-start\"></div>\r\n <div class=\"x-upload-portal-cut-bottom\"></div>\r\n <div class=\"x-upload-portal-cut-bottom-end\"></div>\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"x-upload-portal-bottom-tools\">\r\n <x-icon class=\"x-upload-portal-close\" type=\"fto-check\" (click)=\"sure()\"></x-icon>\r\n </div>\r\n</div>\r\n", styles: ["x-upload-portal{width:100%;height:100%}.x-upload-portal{margin:0;padding:0}.x-upload-portal{display:flex;position:relative;width:100%;height:100%;flex-direction:column}.x-upload-portal-tools{width:100%;height:3.25rem;display:flex;align-items:center;justify-content:space-between;position:absolute;z-index:1;color:#fff}.x-upload-portal-bottom-tools{width:100%;height:3.25rem;position:absolute;display:flex;justify-content:center;align-items:center;z-index:1;color:#fff;bottom:0}.x-upload-portal-title{display:flex;align-items:center;margin:0 1rem}.x-upload-portal-title>x-icon{font-size:1.25rem}.x-upload-portal-title>span{margin-left:.5rem}.x-upload-portal-close{font-size:1.75rem;padding:0 1rem;color:#fffc;transition:color var(--x-animation-duration-base);cursor:pointer}.x-upload-portal-close:hover{color:#fff}.x-upload-portal-img{flex:1;width:100%;position:relative;overflow:auto}.x-upload-portal-full-img{max-width:85%;max-height:85%;width:auto;height:auto;position:absolute;left:50%;top:50%;transform:translate3d(-50%,-50%,0)}.x-upload-portal-clip-img{position:absolute}.x-upload-portal-ready .x-upload-portal-full-img{max-width:inherit;max-height:inherit}.x-upload-portal-boundary{width:0;height:0;left:50%;top:50%;transform:translate3d(-50%,-50%,0);position:relative;background-color:#00000080}.x-upload-portal-cut{width:0;height:0;border:.125rem var(--x-border-style) rgba(255,255,255,.8);display:flex;align-items:center;justify-content:center;position:relative;cursor:move}.x-upload-portal-cut-top-start,.x-upload-portal-cut-top,.x-upload-portal-cut-top-end,.x-upload-portal-cut-left,.x-upload-portal-cut-right,.x-upload-portal-cut-bottom-start,.x-upload-portal-cut-bottom,.x-upload-portal-cut-bottom-end{width:.825rem;height:.825rem;background:#fff;position:absolute;border:var(--x-border-width) var(--x-border-style) var(--x-border);border-radius:var(--x-border-radius)}.x-upload-portal-cut-top-start{top:-.4125rem;left:-.4125rem;cursor:se-resize}.x-upload-portal-cut-top{top:-.4125rem;cursor:s-resize}.x-upload-portal-cut-top-end{top:-.4125rem;right:-.4125rem;cursor:ne-resize}.x-upload-portal-cut-left{left:-.4125rem;cursor:w-resize}.x-upload-portal-cut-right{right:-.4125rem;cursor:w-resize}.x-upload-portal-cut-bottom-start{left:-.4125rem;bottom:-.4125rem;cursor:ne-resize}.x-upload-portal-cut-bottom{bottom:-.4125rem;cursor:s-resize}.x-upload-portal-cut-bottom-end{right:-.4125rem;bottom:-.4125rem;cursor:se-resize}.x-upload-portal-top-start{cursor:se-resize}.x-upload-portal-top{cursor:s-resize}.x-upload-portal-top-end{cursor:ne-resize}.x-upload-portal-left,.x-upload-portal-right{cursor:w-resize}.x-upload-portal-bottom-start{cursor:ne-resize}.x-upload-portal-bottom{cursor:s-resize}.x-upload-portal-bottom-end{cursor:se-resize}\n"] }]
|
|
345
|
-
}] });
|
|
345
|
+
}], propDecorators: { file: [{ type: i0.Input, args: [{ isSignal: true, alias: "file", required: false }] }], imgRef: [{ type: i0.ViewChild, args: ['imgRef', { isSignal: true }] }], imgClipRef: [{ type: i0.ViewChild, args: ['imgClipRef', { isSignal: true }] }], boundaryRef: [{ type: i0.ViewChild, args: ['boundaryRef', { isSignal: true }] }], cutRef: [{ type: i0.ViewChild, args: ['cutRef', { isSignal: true }] }], closePortal: [{ type: i0.Output, args: ["closePortal"] }], surePortal: [{ type: i0.Output, args: ["surePortal"] }] } });
|
|
346
346
|
|
|
347
347
|
class XDragOverlayComponent {
|
|
348
348
|
constructor() {
|
|
@@ -351,13 +351,13 @@ class XDragOverlayComponent {
|
|
|
351
351
|
this.description = input(...(ngDevMode ? [undefined, { debugName: "description" }] : []));
|
|
352
352
|
this.iconString = computed(() => this.icon(), ...(ngDevMode ? [{ debugName: "iconString" }] : []));
|
|
353
353
|
}
|
|
354
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
355
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.
|
|
354
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XDragOverlayComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
355
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.5", type: XDragOverlayComponent, isStandalone: true, selector: "x-drag-overlay", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"x-drag-overlay\">\r\n @if (icon()) {\r\n <div class=\"x-drag-overlay-icon\">\r\n <ng-container *xOutlet=\"icon()\">\r\n <x-icon [type]=\"iconString()\"></x-icon>\r\n </ng-container>\r\n </div>\r\n }\r\n @if (title()) {\r\n <div class=\"x-drag-overlay-title\">\r\n <ng-container *xOutlet=\"title()\">\r\n {{ title() }}\r\n </ng-container>\r\n </div>\r\n }\r\n @if (description()) {\r\n <div class=\"x-drag-overlay-description\">\r\n <ng-container *xOutlet=\"description()\">\r\n {{ description() }}\r\n </ng-container>\r\n </div>\r\n }\r\n</div>\r\n", styles: ["x-drag-overlay{width:100%;height:100%}.x-drag-overlay{margin:0;padding:0}.x-drag-overlay{position:absolute;inset:0;-webkit-backdrop-filter:blur(.25rem);backdrop-filter:blur(.25rem);border:var(--x-border-width) dashed var(--x-primary);display:flex;flex-direction:column;align-items:center;justify-content:center;z-index:1000}.x-drag-overlay-icon{font-size:2rem}.x-drag-overlay-title{font-size:1rem}.x-drag-overlay-description{color:var(--x-text-400)}\n"], dependencies: [{ kind: "directive", type: XOutletDirective, selector: "[xOutlet]", inputs: ["xOutletContext", "xOutlet"] }, { kind: "component", type: XIconComponent, selector: "x-icon" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
356
356
|
}
|
|
357
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
357
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XDragOverlayComponent, decorators: [{
|
|
358
358
|
type: Component,
|
|
359
359
|
args: [{ selector: 'x-drag-overlay', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, imports: [XOutletDirective, XIconComponent], template: "<div class=\"x-drag-overlay\">\r\n @if (icon()) {\r\n <div class=\"x-drag-overlay-icon\">\r\n <ng-container *xOutlet=\"icon()\">\r\n <x-icon [type]=\"iconString()\"></x-icon>\r\n </ng-container>\r\n </div>\r\n }\r\n @if (title()) {\r\n <div class=\"x-drag-overlay-title\">\r\n <ng-container *xOutlet=\"title()\">\r\n {{ title() }}\r\n </ng-container>\r\n </div>\r\n }\r\n @if (description()) {\r\n <div class=\"x-drag-overlay-description\">\r\n <ng-container *xOutlet=\"description()\">\r\n {{ description() }}\r\n </ng-container>\r\n </div>\r\n }\r\n</div>\r\n", styles: ["x-drag-overlay{width:100%;height:100%}.x-drag-overlay{margin:0;padding:0}.x-drag-overlay{position:absolute;inset:0;-webkit-backdrop-filter:blur(.25rem);backdrop-filter:blur(.25rem);border:var(--x-border-width) dashed var(--x-primary);display:flex;flex-direction:column;align-items:center;justify-content:center;z-index:1000}.x-drag-overlay-icon{font-size:2rem}.x-drag-overlay-title{font-size:1rem}.x-drag-overlay-description{color:var(--x-text-400)}\n"] }]
|
|
360
|
-
}] });
|
|
360
|
+
}], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }] } });
|
|
361
361
|
|
|
362
362
|
class XDragOverlayService {
|
|
363
363
|
constructor() {
|
|
@@ -369,14 +369,15 @@ class XDragOverlayService {
|
|
|
369
369
|
this.factory = inject(RendererFactory2);
|
|
370
370
|
this.renderer = this.factory.createRenderer(null, null);
|
|
371
371
|
}
|
|
372
|
-
createOverlay(container, params) {
|
|
372
|
+
createOverlay(container, viewContainerRef, params) {
|
|
373
373
|
this.removeOverlay(container);
|
|
374
|
+
const isBodyOrWindow = container === this.document.body || container === this.document.documentElement;
|
|
374
375
|
this.containerPosition = container.style.position;
|
|
375
376
|
this.renderer.setStyle(container, 'position', 'relative');
|
|
376
377
|
const overlayConfig = new OverlayConfig({
|
|
377
378
|
positionStrategy: this.overlay.position().global(),
|
|
378
379
|
hasBackdrop: false,
|
|
379
|
-
scrollStrategy: this.overlay.scrollStrategies.
|
|
380
|
+
scrollStrategy: this.overlay.scrollStrategies.block()
|
|
380
381
|
});
|
|
381
382
|
this.overlayRef = this.overlay.create(overlayConfig);
|
|
382
383
|
if (this.overlayRef && this.overlayRef.overlayElement) {
|
|
@@ -387,13 +388,15 @@ class XDragOverlayService {
|
|
|
387
388
|
this.renderer.setStyle(this.overlayRef.overlayElement, 'pointer-events', 'none');
|
|
388
389
|
this.renderer.setStyle(this.overlayRef.overlayElement, 'z-index', 'none');
|
|
389
390
|
}
|
|
390
|
-
const portal = new ComponentPortal(XDragOverlayComponent);
|
|
391
|
+
const portal = new ComponentPortal(XDragOverlayComponent, viewContainerRef);
|
|
391
392
|
this.componentRef = this.overlayRef.attach(portal);
|
|
392
393
|
this.componentRef.setInput('icon', params.icon);
|
|
393
394
|
this.componentRef.setInput('title', params.title);
|
|
394
395
|
this.componentRef.setInput('description', params.description);
|
|
395
396
|
if (this.overlayRef && this.overlayRef.overlayElement) {
|
|
396
|
-
|
|
397
|
+
if (!isBodyOrWindow) {
|
|
398
|
+
container.appendChild(this.overlayRef.overlayElement);
|
|
399
|
+
}
|
|
397
400
|
}
|
|
398
401
|
}
|
|
399
402
|
removeOverlay(container) {
|
|
@@ -411,10 +414,10 @@ class XDragOverlayService {
|
|
|
411
414
|
this.componentRef = null;
|
|
412
415
|
}
|
|
413
416
|
}
|
|
414
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
415
|
-
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.
|
|
417
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XDragOverlayService, deps: [], target: i0.ɵɵFactoryTarget.Injectable }); }
|
|
418
|
+
/** @nocollapse */ static { this.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XDragOverlayService, providedIn: 'root' }); }
|
|
416
419
|
}
|
|
417
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
420
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XDragOverlayService, decorators: [{
|
|
418
421
|
type: Injectable,
|
|
419
422
|
args: [{
|
|
420
423
|
providedIn: 'root'
|
|
@@ -520,7 +523,7 @@ class XUploadComponent extends XUploadProperty {
|
|
|
520
523
|
const icon = this.dropIcon();
|
|
521
524
|
const title = this.dropTitle();
|
|
522
525
|
const description = this.dropDescription();
|
|
523
|
-
this.dragOverlayService.createOverlay(element, { icon, title, description });
|
|
526
|
+
this.dragOverlayService.createOverlay(element, this.viewContainerRef, { icon, title, description });
|
|
524
527
|
}
|
|
525
528
|
}
|
|
526
529
|
removeDragOverStyle(element) {
|
|
@@ -704,10 +707,10 @@ class XUploadComponent extends XUploadProperty {
|
|
|
704
707
|
imgLoad(file) {
|
|
705
708
|
file.state = 'success';
|
|
706
709
|
}
|
|
707
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
708
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.
|
|
710
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
711
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.5", type: XUploadComponent, isStandalone: true, selector: "x-upload", host: { properties: { "class.x-upload-show-drop": "this.getShowDrop" } }, providers: [XValueAccessor(XUploadComponent), XDragOverlayService], viewQueries: [{ propertyName: "file", first: true, predicate: ["file"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div #upload class=\"x-upload x-upload-{{ type() }}\" [class.x-disabled]=\"disabledComputed()\">\r\n <input\r\n class=\"x-upload-input\"\r\n type=\"file\"\r\n #file\r\n (change)=\"change($event)\"\r\n [attr.accept]=\"acceptSignal()\"\r\n [multiple]=\"multiple()\"\r\n style=\"display: none\"\r\n />\r\n\r\n @switch (type()) {\r\n @case ('list') {\r\n <ng-container *ngTemplateOutlet=\"uploadBtnTpl\"></ng-container>\r\n <ng-container *xOutlet=\"filesTpl(); context: { $files: files() }\">\r\n @if (files() && files().length > 0) {\r\n <ul class=\"x-upload-files\">\r\n @for (file of files(); track file; let i = $index) {\r\n <li [class.x-upload-disabled]=\"!download()\">\r\n @if (download()) {\r\n <a [href]=\"file.url\" target=\"_blank\" [title]=\"file.name\">\r\n <x-icon type=\"fto-file-text\"></x-icon>\r\n <span class=\"x-upload-filename\">{{ file.name }}</span>\r\n </a>\r\n } @else {\r\n <a>\r\n <x-icon type=\"fto-file-text\"></x-icon>\r\n <span class=\"x-upload-filename\">{{ file.name }}</span>\r\n </a>\r\n }\r\n\r\n @switch (file.state) {\r\n @case ('ready') {\r\n <x-icon class=\"x-upload-state\" type=\"fto-clock\"></x-icon>\r\n }\r\n @case ('uploading') {\r\n <span class=\"x-upload-percent\">{{ file.percent }}%</span>\r\n }\r\n @case ('success') {\r\n <x-icon class=\"x-upload-state success\" type=\"fto-check\"></x-icon>\r\n }\r\n @case ('error') {\r\n <x-icon class=\"x-upload-state error\" type=\"fto-info\"></x-icon>\r\n }\r\n }\r\n @if (file.state !== 'uploading') {\r\n <x-button icon=\"fto-x\" (click)=\"remove(file, i)\" closable onlyIcon flat size=\"mini\"></x-button>\r\n }\r\n </li>\r\n }\r\n </ul>\r\n }\r\n </ng-container>\r\n }\r\n @case ('img') {\r\n <x-image-group>\r\n @for (file of files(); track file; let i = $index) {\r\n <x-image\r\n [src]=\"file.url\"\r\n (load)=\"imgLoad(file)\"\r\n (error)=\"imgError($event, file)\"\r\n class=\"{{ file.state }}\"\r\n [previewTpl]=\"previewTpl\"\r\n [fallback]=\"imgFallback()\"\r\n >\r\n </x-image>\r\n <ng-template #previewTpl let-image=\"$image\">\r\n @if (file.state == 'uploading') {\r\n <div class=\"x-upload-uploading\">\r\n <x-progress [percent]=\"file.percent!\" info=\"false\"></x-progress>\r\n </div>\r\n }\r\n <div class=\"x-image-overlay\">\r\n @switch (file.state) {\r\n @case ('ready') {\r\n <x-icon class=\"x-upload-state\" type=\"fto-clock\"></x-icon>\r\n }\r\n @case ('success') {\r\n <x-icon type=\"fto-eye\" (click)=\"image.onPreview()\"></x-icon>\r\n }\r\n }\r\n @if (imgCut() && file.state === 'success') {\r\n <x-icon type=\"fto-crop\" (click)=\"onImgCut(file, i)\"></x-icon>\r\n }\r\n @if (file.state !== 'uploading') {\r\n <x-icon type=\"fto-trash-2\" (click)=\"remove(file, i)\"></x-icon>\r\n }\r\n </div>\r\n </ng-template>\r\n }\r\n <ng-container *ngTemplateOutlet=\"uploadBtnTpl\"></ng-container>\r\n </x-image-group>\r\n }\r\n }\r\n</div>\r\n\r\n<ng-template #uploadBtnTpl>\r\n @if (showDrop()) {\r\n <x-drag-overlay\r\n class=\"x-upload-drag-overlay\"\r\n (click)=\"uploadClick()\"\r\n [icon]=\"dropIcon()\"\r\n [title]=\"dropTitle()\"\r\n [description]=\"dropDescription()\"\r\n ></x-drag-overlay>\r\n } @else {\r\n <div class=\"x-upload-buttons\" [class.x-upload-buttons-template]=\"isTemplateText()\" (click)=\"uploadClick()\">\r\n <ng-container *xOutlet=\"getText()\">\r\n <x-button icon=\"fto-upload\" class=\"x-upload-text\" [disabled]=\"disabledComputed()\" type=\"primary\">{{\r\n getText()\r\n }}</x-button>\r\n </ng-container>\r\n </div>\r\n }\r\n</ng-template>\r\n", styles: [".x-upload{margin:0;padding:0}.x-upload{color:var(--x-text);font-size:var(--x-font-size)}.x-upload-buttons{display:inline-flex}.x-upload-buttons>.x-button:not(:first-child){margin-left:.4rem}.x-upload-buttons-template{cursor:pointer}.x-upload-files{padding:0;margin:.4rem 0 0;list-style:none}.x-upload-files>li{margin:0;padding:0 .2rem;height:calc(var(--x-font-size) + .6rem);line-height:calc(var(--x-font-size) + .6rem);display:flex;align-items:center;overflow:hidden;cursor:pointer;border-radius:var(--x-border-radius)}.x-upload-files>li .x-icon{color:var(--x-text-400);font-size:1rem}.x-upload-files>li .x-icon.x-upload-state.success{color:var(--x-success)}.x-upload-files>li .x-icon.x-upload-state.error{color:var(--x-danger)}.x-upload-files>li a{flex:1;display:flex;align-items:center;height:calc(var(--x-font-size) + .6rem);line-height:calc(var(--x-font-size) + .6rem);color:inherit;text-decoration:none;overflow:hidden}.x-upload-files>li span.x-upload-filename{margin-left:.2rem;flex:1;white-space:nowrap;text-overflow:ellipsis;overflow:hidden}.x-upload-files>li span.x-upload-percent{color:var(--x-text-400)}.x-upload-files>li>.x-button{display:none;padding:0}.x-upload-files>li:not(:first-child){margin-top:.2rem}.x-upload-files>li.x-upload-disabled{cursor:default}.x-upload-files>li.x-upload-disabled>a{cursor:default}.x-upload-files>li:hover:not(.x-upload-disabled){color:var(--x-primary);background-color:var(--x-background)}.x-upload-files>li:hover>.x-button{display:inline-block}.x-upload-files>li:hover>.x-upload-state{display:none}.x-upload-img{display:flex;flex-wrap:wrap}.x-upload-img .x-upload-buttons-template{display:inline-flex;align-items:center;justify-content:center;flex-direction:column;width:6.25rem;height:6.25rem;margin-right:.5rem;margin-bottom:.5rem;border:var(--x-border-width) dashed var(--x-border);background:var(--x-background);border-radius:var(--x-border-radius);transition:border-color var(--x-animation-duration-base)}.x-upload-img .x-upload-buttons-template:hover{border-color:var(--x-primary)}.x-upload-img .x-image{height:6.25rem;width:6.25rem;padding:.325rem;border:var(--x-border-width) var(--x-border-style) var(--x-border);border-radius:var(--x-border-radius);transition:border-color var(--x-animation-duration-base);margin-right:.5rem;margin-bottom:.5rem;position:relative;display:flex;align-items:center;justify-content:center}.x-upload-img .x-image-overlay{border-radius:var(--x-border-radius)}.x-upload-img .x-image-overlay x-icon{font-size:1rem;color:#fffc;padding:.25rem;transition:color var(--x-animation-duration-base)}.x-upload-img .x-image-overlay x-icon:hover{color:#fff}.x-upload-img x-image.error .x-image{border-color:var(--x-danger)}.x-upload-img x-image.error .x-image-error-icon{color:var(--x-danger)}.x-upload-uploading{position:absolute;margin-top:3rem;width:calc(100% - 1rem)}.x-upload-show-drop{position:relative;display:block;width:100%;height:100%}.x-upload-drag-overlay .x-drag-overlay{border:var(--x-border-width) dashed var(--x-border);cursor:pointer;transition:all var(--x-animation-duration-base)}.x-upload-drag-overlay .x-drag-overlay:hover,.x-upload-drag-over .x-drag-overlay{border-color:var(--x-primary)}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: XIconComponent, selector: "x-icon" }, { kind: "directive", type: XOutletDirective, selector: "[xOutlet]", inputs: ["xOutletContext", "xOutlet"] }, { kind: "component", type: XButtonComponent, selector: "x-button" }, { kind: "component", type: XImageGroupComponent, selector: "x-image-group" }, { kind: "component", type: XImageComponent, selector: "x-image" }, { kind: "component", type: XProgressComponent, selector: "x-progress" }, { kind: "component", type: XDragOverlayComponent, selector: "x-drag-overlay", inputs: ["icon", "title", "description"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
709
712
|
}
|
|
710
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
713
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadComponent, decorators: [{
|
|
711
714
|
type: Component,
|
|
712
715
|
args: [{ selector: `${XUploadPrefix}`, imports: [
|
|
713
716
|
NgTemplateOutlet,
|
|
@@ -722,14 +725,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.0", ngImpor
|
|
|
722
725
|
}], ctorParameters: () => [], propDecorators: { getShowDrop: [{
|
|
723
726
|
type: HostBinding,
|
|
724
727
|
args: ['class.x-upload-show-drop']
|
|
725
|
-
}] } });
|
|
728
|
+
}], file: [{ type: i0.ViewChild, args: ['file', { isSignal: true }] }] } });
|
|
726
729
|
|
|
727
730
|
class XUploadModule {
|
|
728
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.
|
|
729
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.
|
|
730
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.
|
|
731
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
732
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.3.5", ngImport: i0, type: XUploadModule, imports: [XUploadComponent], exports: [XUploadComponent] }); }
|
|
733
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadModule, imports: [XUploadComponent] }); }
|
|
731
734
|
}
|
|
732
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.
|
|
735
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.5", ngImport: i0, type: XUploadModule, decorators: [{
|
|
733
736
|
type: NgModule,
|
|
734
737
|
args: [{
|
|
735
738
|
exports: [XUploadComponent],
|