@ng-nest/ui 20.0.7 → 20.1.0
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 +33 -8
- package/base-form/index.d.ts +3 -3
- package/calendar/index.d.ts +1 -2
- package/cascade/index.d.ts +33 -8
- package/checkbox/index.d.ts +3 -3
- package/color-picker/index.d.ts +34 -8
- package/core/index.d.ts +40 -8
- package/date-picker/index.d.ts +57 -12
- package/dropdown/index.d.ts +4 -4
- package/fesm2022/ng-nest-ui-affix.mjs +12 -12
- package/fesm2022/ng-nest-ui-affix.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-alert.mjs +35 -35
- package/fesm2022/ng-nest-ui-alert.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-anchor.mjs +31 -31
- 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-auto-complete.mjs +82 -72
- package/fesm2022/ng-nest-ui-auto-complete.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-avatar.mjs +31 -31
- package/fesm2022/ng-nest-ui-avatar.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-back-top.mjs +18 -18
- package/fesm2022/ng-nest-ui-back-top.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-badge.mjs +23 -23
- package/fesm2022/ng-nest-ui-badge.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-base-form.mjs +45 -45
- package/fesm2022/ng-nest-ui-base-form.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-button.mjs +42 -42
- package/fesm2022/ng-nest-ui-button.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-calendar.mjs +20 -20
- package/fesm2022/ng-nest-ui-calendar.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-card.mjs +15 -15
- package/fesm2022/ng-nest-ui-card.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-carousel.mjs +46 -46
- package/fesm2022/ng-nest-ui-carousel.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-cascade.mjs +86 -76
- package/fesm2022/ng-nest-ui-cascade.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-checkbox.mjs +39 -39
- package/fesm2022/ng-nest-ui-checkbox.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-collapse.mjs +31 -31
- package/fesm2022/ng-nest-ui-collapse.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-color-picker.mjs +91 -72
- package/fesm2022/ng-nest-ui-color-picker.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-color.mjs +16 -16
- package/fesm2022/ng-nest-ui-color.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-comment.mjs +21 -21
- package/fesm2022/ng-nest-ui-comment.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-container.mjs +37 -37
- package/fesm2022/ng-nest-ui-container.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-core.mjs +38 -22
- package/fesm2022/ng-nest-ui-core.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-crumb.mjs +13 -13
- package/fesm2022/ng-nest-ui-crumb.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-date-picker.mjs +273 -253
- package/fesm2022/ng-nest-ui-date-picker.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-description.mjs +31 -31
- package/fesm2022/ng-nest-ui-description.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-dialog.mjs +81 -81
- 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 +10 -10
- package/fesm2022/ng-nest-ui-drag.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-drawer.mjs +42 -42
- package/fesm2022/ng-nest-ui-drawer.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-dropdown.mjs +49 -49
- package/fesm2022/ng-nest-ui-dropdown.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-empty.mjs +12 -12
- package/fesm2022/ng-nest-ui-empty.mjs.map +1 -1
- 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 +79 -77
- package/fesm2022/ng-nest-ui-find.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-form.mjs +33 -33
- package/fesm2022/ng-nest-ui-form.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-highlight.mjs +20 -20
- package/fesm2022/ng-nest-ui-highlight.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-i18n.mjs +15 -15
- package/fesm2022/ng-nest-ui-i18n.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-icon.mjs +21 -21
- package/fesm2022/ng-nest-ui-icon.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-image.mjs +39 -39
- 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 +42 -42
- package/fesm2022/ng-nest-ui-input-number.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-input.mjs +102 -81
- package/fesm2022/ng-nest-ui-input.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-keyword.mjs +15 -15
- package/fesm2022/ng-nest-ui-keyword.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-layout.mjs +31 -31
- package/fesm2022/ng-nest-ui-layout.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-link.mjs +18 -18
- package/fesm2022/ng-nest-ui-link.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-list.mjs +80 -80
- package/fesm2022/ng-nest-ui-list.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-loading.mjs +22 -22
- package/fesm2022/ng-nest-ui-loading.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-menu.mjs +45 -45
- package/fesm2022/ng-nest-ui-menu.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-message-box.mjs +10 -10
- package/fesm2022/ng-nest-ui-message-box.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-message.mjs +10 -10
- package/fesm2022/ng-nest-ui-message.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-notification.mjs +10 -10
- package/fesm2022/ng-nest-ui-notification.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-outlet.mjs +9 -9
- package/fesm2022/ng-nest-ui-outlet.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-page-header.mjs +15 -15
- package/fesm2022/ng-nest-ui-page-header.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-pagination.mjs +53 -53
- 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 +27 -27
- package/fesm2022/ng-nest-ui-popconfirm.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-popover.mjs +38 -38
- package/fesm2022/ng-nest-ui-popover.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-portal.mjs +7 -7
- package/fesm2022/ng-nest-ui-portal.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-progress.mjs +38 -38
- package/fesm2022/ng-nest-ui-progress.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-radio.mjs +36 -36
- package/fesm2022/ng-nest-ui-radio.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-rate.mjs +30 -30
- package/fesm2022/ng-nest-ui-rate.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-resizable.mjs +16 -16
- package/fesm2022/ng-nest-ui-resizable.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-result.mjs +16 -16
- package/fesm2022/ng-nest-ui-result.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-ripple.mjs +13 -13
- package/fesm2022/ng-nest-ui-ripple.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-scrollable.mjs +102 -19
- package/fesm2022/ng-nest-ui-scrollable.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-select.mjs +121 -111
- package/fesm2022/ng-nest-ui-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-skeleton.mjs +15 -15
- package/fesm2022/ng-nest-ui-skeleton.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-slider-select.mjs +54 -54
- package/fesm2022/ng-nest-ui-slider-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-slider.mjs +39 -39
- package/fesm2022/ng-nest-ui-slider.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-statistic.mjs +30 -30
- package/fesm2022/ng-nest-ui-statistic.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-steps.mjs +19 -19
- package/fesm2022/ng-nest-ui-steps.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-switch.mjs +26 -26
- package/fesm2022/ng-nest-ui-switch.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-table-view.mjs +490 -242
- package/fesm2022/ng-nest-ui-table-view.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-table.mjs +221 -221
- package/fesm2022/ng-nest-ui-table.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tabs.mjs +58 -58
- package/fesm2022/ng-nest-ui-tabs.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tag.mjs +22 -22
- package/fesm2022/ng-nest-ui-tag.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-text-retract.mjs +15 -15
- package/fesm2022/ng-nest-ui-text-retract.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-textarea.mjs +41 -41
- package/fesm2022/ng-nest-ui-textarea.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-theme.mjs +23 -23
- package/fesm2022/ng-nest-ui-theme.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-time-ago.mjs +7 -7
- package/fesm2022/ng-nest-ui-time-ago.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-time-picker.mjs +104 -94
- 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-time-range.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-timeline.mjs +15 -15
- package/fesm2022/ng-nest-ui-timeline.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tooltip.mjs +38 -38
- package/fesm2022/ng-nest-ui-tooltip.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-transfer.mjs +40 -40
- package/fesm2022/ng-nest-ui-transfer.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tree-file.mjs +28 -28
- package/fesm2022/ng-nest-ui-tree-file.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tree-select.mjs +126 -116
- package/fesm2022/ng-nest-ui-tree-select.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-tree.mjs +107 -107
- package/fesm2022/ng-nest-ui-tree.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-typography.mjs +13 -13
- package/fesm2022/ng-nest-ui-typography.mjs.map +1 -1
- package/fesm2022/ng-nest-ui-upload.mjs +37 -37
- package/fesm2022/ng-nest-ui-upload.mjs.map +1 -1
- package/find/index.d.ts +5 -5
- package/form/index.d.ts +1 -1
- package/input/index.d.ts +32 -5
- package/input-number/index.d.ts +5 -5
- package/list/index.d.ts +2 -2
- package/message-box/index.d.ts +4 -5
- package/package.json +20 -20
- package/radio/index.d.ts +3 -3
- package/rate/index.d.ts +5 -5
- package/scrollable/index.d.ts +15 -7
- package/select/index.d.ts +38 -8
- package/slider-select/index.d.ts +3 -3
- package/steps/index.d.ts +1 -2
- package/switch/index.d.ts +3 -3
- package/table-view/index.d.ts +121 -79
- package/textarea/index.d.ts +3 -3
- package/theme/index.d.ts +1 -1
- package/time-picker/index.d.ts +33 -8
- package/transfer/index.d.ts +1 -1
- package/tree-select/index.d.ts +33 -8
- package/upload/index.d.ts +2 -2
|
@@ -29,7 +29,7 @@ class XRowProperty extends XPropertyFunction(X_ROW_CONFIG_NAME) {
|
|
|
29
29
|
* ```
|
|
30
30
|
*
|
|
31
31
|
*/
|
|
32
|
-
this.space = input('', { transform: XToCssPixelValue });
|
|
32
|
+
this.space = input('', ...(ngDevMode ? [{ debugName: "space", transform: XToCssPixelValue }] : [{ transform: XToCssPixelValue }]));
|
|
33
33
|
/**
|
|
34
34
|
* @zh_CN flex 布局下的水平排列方式
|
|
35
35
|
* @en_US Horizontal arrangement under flex layout
|
|
@@ -43,7 +43,7 @@ class XRowProperty extends XPropertyFunction(X_ROW_CONFIG_NAME) {
|
|
|
43
43
|
* ```
|
|
44
44
|
*
|
|
45
45
|
*/
|
|
46
|
-
this.justify = input();
|
|
46
|
+
this.justify = input(...(ngDevMode ? [undefined, { debugName: "justify" }] : []));
|
|
47
47
|
/**
|
|
48
48
|
* @zh_CN flex 布局下的垂直排列方式
|
|
49
49
|
* @en_US Vertical arrangement under flex layout
|
|
@@ -57,12 +57,12 @@ class XRowProperty extends XPropertyFunction(X_ROW_CONFIG_NAME) {
|
|
|
57
57
|
* ```
|
|
58
58
|
*
|
|
59
59
|
*/
|
|
60
|
-
this.align = input();
|
|
60
|
+
this.align = input(...(ngDevMode ? [undefined, { debugName: "align" }] : []));
|
|
61
61
|
}
|
|
62
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
63
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.
|
|
62
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XRowProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
63
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.2.4", type: XRowProperty, isStandalone: true, selector: "x-row-property", inputs: { space: { classPropertyName: "space", publicName: "space", isSignal: true, isRequired: false, transformFunction: null }, justify: { classPropertyName: "justify", publicName: "justify", isSignal: true, isRequired: false, transformFunction: null }, align: { classPropertyName: "align", publicName: "align", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
|
|
64
64
|
}
|
|
65
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
65
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XRowProperty, decorators: [{
|
|
66
66
|
type: Component,
|
|
67
67
|
args: [{ selector: `${XRowPrefix}-property`, template: '' }]
|
|
68
68
|
}] });
|
|
@@ -92,7 +92,7 @@ class XColProperty extends XPropertyFunction(X_COL_CONFIG_NAME) {
|
|
|
92
92
|
* ```
|
|
93
93
|
*
|
|
94
94
|
*/
|
|
95
|
-
this.span = input(24, { transform: XToNumber });
|
|
95
|
+
this.span = input(24, ...(ngDevMode ? [{ debugName: "span", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
96
96
|
/**
|
|
97
97
|
* @zh_CN 栅格左侧的间隔格数
|
|
98
98
|
* @en_US The number of intervals on the left side of the grid
|
|
@@ -106,27 +106,27 @@ class XColProperty extends XPropertyFunction(X_COL_CONFIG_NAME) {
|
|
|
106
106
|
* ```
|
|
107
107
|
*
|
|
108
108
|
*/
|
|
109
|
-
this.offset = input(0, { transform: XToNumber });
|
|
109
|
+
this.offset = input(0, ...(ngDevMode ? [{ debugName: "offset", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
110
110
|
/**
|
|
111
111
|
* <768px
|
|
112
112
|
*/
|
|
113
|
-
this.xs = input(0, { transform: XToNumber });
|
|
113
|
+
this.xs = input(0, ...(ngDevMode ? [{ debugName: "xs", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
114
114
|
/**
|
|
115
115
|
* ≥768px
|
|
116
116
|
*/
|
|
117
|
-
this.sm = input(0, { transform: XToNumber });
|
|
117
|
+
this.sm = input(0, ...(ngDevMode ? [{ debugName: "sm", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
118
118
|
/**
|
|
119
119
|
* ≥992px
|
|
120
120
|
*/
|
|
121
|
-
this.md = input(0, { transform: XToNumber });
|
|
121
|
+
this.md = input(0, ...(ngDevMode ? [{ debugName: "md", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
122
122
|
/**
|
|
123
123
|
* ≥1200px
|
|
124
124
|
*/
|
|
125
|
-
this.lg = input(0, { transform: XToNumber });
|
|
125
|
+
this.lg = input(0, ...(ngDevMode ? [{ debugName: "lg", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
126
126
|
/**
|
|
127
127
|
* ≥1920px
|
|
128
128
|
*/
|
|
129
|
-
this.xl = input(0, { transform: XToNumber });
|
|
129
|
+
this.xl = input(0, ...(ngDevMode ? [{ debugName: "xl", transform: XToNumber }] : [{ transform: XToNumber }]));
|
|
130
130
|
/**
|
|
131
131
|
* @zh_CN 默认样式
|
|
132
132
|
* @en_US Default style
|
|
@@ -140,12 +140,12 @@ class XColProperty extends XPropertyFunction(X_COL_CONFIG_NAME) {
|
|
|
140
140
|
* ```
|
|
141
141
|
*
|
|
142
142
|
*/
|
|
143
|
-
this.inherit = input(false, { transform: XToBoolean });
|
|
143
|
+
this.inherit = input(false, ...(ngDevMode ? [{ debugName: "inherit", transform: XToBoolean }] : [{ transform: XToBoolean }]));
|
|
144
144
|
}
|
|
145
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
146
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.
|
|
145
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XColProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
146
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.2.4", type: XColProperty, isStandalone: true, selector: "x-col-property", inputs: { span: { classPropertyName: "span", publicName: "span", isSignal: true, isRequired: false, transformFunction: null }, offset: { classPropertyName: "offset", publicName: "offset", isSignal: true, isRequired: false, transformFunction: null }, xs: { classPropertyName: "xs", publicName: "xs", isSignal: true, isRequired: false, transformFunction: null }, sm: { classPropertyName: "sm", publicName: "sm", isSignal: true, isRequired: false, transformFunction: null }, md: { classPropertyName: "md", publicName: "md", isSignal: true, isRequired: false, transformFunction: null }, lg: { classPropertyName: "lg", publicName: "lg", isSignal: true, isRequired: false, transformFunction: null }, xl: { classPropertyName: "xl", publicName: "xl", isSignal: true, isRequired: false, transformFunction: null }, inherit: { classPropertyName: "inherit", publicName: "inherit", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
|
|
147
147
|
}
|
|
148
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
148
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XColProperty, decorators: [{
|
|
149
149
|
type: Component,
|
|
150
150
|
args: [{ selector: `${XColPrefix}-property`, template: '' }]
|
|
151
151
|
}] });
|
|
@@ -154,13 +154,13 @@ class XRowComponent extends XRowProperty {
|
|
|
154
154
|
constructor() {
|
|
155
155
|
super(...arguments);
|
|
156
156
|
this.document = inject(DOCUMENT);
|
|
157
|
-
this.fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));
|
|
157
|
+
this.fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')), ...(ngDevMode ? [{ debugName: "fontSize" }] : []));
|
|
158
158
|
this.spaceSignal = computed(() => {
|
|
159
159
|
if (!this.space())
|
|
160
160
|
return 0;
|
|
161
161
|
const space = this.space();
|
|
162
162
|
return XToCssPx(space, this.fontSize());
|
|
163
|
-
});
|
|
163
|
+
}, ...(ngDevMode ? [{ debugName: "spaceSignal" }] : []));
|
|
164
164
|
}
|
|
165
165
|
get getFlex() {
|
|
166
166
|
return this.justify() || this.align() ? true : false;
|
|
@@ -179,10 +179,10 @@ class XRowComponent extends XRowProperty {
|
|
|
179
179
|
get marginRight() {
|
|
180
180
|
return `-${this.spaceSignal() / 2}px`;
|
|
181
181
|
}
|
|
182
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
183
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.
|
|
182
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XRowComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
183
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.2.4", type: XRowComponent, isStandalone: true, selector: "x-row", host: { properties: { "class.x-flex": "this.getFlex", "class": "this.cls", "style.marginLeft": "this.marginLeft", "style.marginRight": "this.marginRight" } }, usesInheritance: true, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, styles: [".x-row{display:block;position:relative;height:auto}.x-row:before,.x-row:after{content:\"\";display:table;clear:both}.x-row.x-flex{display:flex}.x-row.x-justify-start{justify-content:flex-start}.x-row.x-justify-center{justify-content:center}.x-row.x-justify-end{justify-content:flex-end}.x-row.x-justify-space-between{justify-content:space-between}.x-row.x-justify-space-around{justify-content:space-around}.x-row.x-align-start{align-items:flex-start}.x-row.x-align-center{align-items:center}.x-row.x-align-end{align-items:flex-end}.x-row.x-direction-column{flex-direction:column}.x-row.x-direction-column-reverse{flex-direction:column-reverse}.x-row.x-direction-row{flex-direction:row}.x-row.x-direction-row-reverse{flex-direction:row-reverse}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
184
184
|
}
|
|
185
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
185
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XRowComponent, decorators: [{
|
|
186
186
|
type: Component,
|
|
187
187
|
args: [{ selector: `${XRowPrefix}`, template: '<ng-content></ng-content>', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".x-row{display:block;position:relative;height:auto}.x-row:before,.x-row:after{content:\"\";display:table;clear:both}.x-row.x-flex{display:flex}.x-row.x-justify-start{justify-content:flex-start}.x-row.x-justify-center{justify-content:center}.x-row.x-justify-end{justify-content:flex-end}.x-row.x-justify-space-between{justify-content:space-between}.x-row.x-justify-space-around{justify-content:space-around}.x-row.x-align-start{align-items:flex-start}.x-row.x-align-center{align-items:center}.x-row.x-align-end{align-items:flex-end}.x-row.x-direction-column{flex-direction:column}.x-row.x-direction-column-reverse{flex-direction:column-reverse}.x-row.x-direction-row{flex-direction:row}.x-row.x-direction-row-reverse{flex-direction:row-reverse}\n"] }]
|
|
188
188
|
}], propDecorators: { getFlex: [{
|
|
@@ -204,13 +204,13 @@ class XColComponent extends XColProperty {
|
|
|
204
204
|
super(...arguments);
|
|
205
205
|
this.rowComponent = inject(XRowComponent, { optional: true, host: true });
|
|
206
206
|
this.document = inject(DOCUMENT);
|
|
207
|
-
this.fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));
|
|
207
|
+
this.fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')), ...(ngDevMode ? [{ debugName: "fontSize" }] : []));
|
|
208
208
|
this.space = computed(() => {
|
|
209
209
|
if (!this.rowComponent?.space())
|
|
210
210
|
return 0;
|
|
211
211
|
const space = this.rowComponent.space();
|
|
212
212
|
return XToCssPx(space, this.fontSize());
|
|
213
|
-
});
|
|
213
|
+
}, ...(ngDevMode ? [{ debugName: "space" }] : []));
|
|
214
214
|
}
|
|
215
215
|
get getFlex() {
|
|
216
216
|
return this.xs() || this.sm() || this.md() || this.lg() || this.xl() || this.span() == 24 ? true : false;
|
|
@@ -241,10 +241,10 @@ class XColComponent extends XColProperty {
|
|
|
241
241
|
get paddingRight() {
|
|
242
242
|
return `${this.space() / 2}px`;
|
|
243
243
|
}
|
|
244
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
245
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.0.0", type: XColComponent, isStandalone: true, selector: "x-col", host: { properties: { "class.x-col-24": "this.getFlex", "class": "this.cls", "style.paddingLeft": "this.paddingLeft", "style.paddingRight": "this.paddingRight" } }, usesInheritance: true, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, styles: [".x-col{position:relative;float:left;display:block;width:100%;box-sizing:border-box}.x-col-24{width:100%}.x-col-offset-24{margin-left:100%}.x-col-23{width:95.8333333333%}.x-col-offset-23{margin-left:95.8333333333%}.x-col-22{width:91.6666666667%}.x-col-offset-22{margin-left:91.6666666667%}.x-col-21{width:87.5%}.x-col-offset-21{margin-left:87.5%}.x-col-20{width:83.3333333333%}.x-col-offset-20{margin-left:83.3333333333%}.x-col-19{width:79.1666666667%}.x-col-offset-19{margin-left:79.1666666667%}.x-col-18{width:75%}.x-col-offset-18{margin-left:75%}.x-col-17{width:70.8333333333%}.x-col-offset-17{margin-left:70.8333333333%}.x-col-16{width:66.6666666667%}.x-col-offset-16{margin-left:66.6666666667%}.x-col-15{width:62.5%}.x-col-offset-15{margin-left:62.5%}.x-col-14{width:58.3333333333%}.x-col-offset-14{margin-left:58.3333333333%}.x-col-13{width:54.1666666667%}.x-col-offset-13{margin-left:54.1666666667%}.x-col-12{width:50%}.x-col-offset-12{margin-left:50%}.x-col-11{width:45.8333333333%}.x-col-offset-11{margin-left:45.8333333333%}.x-col-10{width:41.6666666667%}.x-col-offset-10{margin-left:41.6666666667%}.x-col-9{width:37.5%}.x-col-offset-9{margin-left:37.5%}.x-col-8{width:33.3333333333%}.x-col-offset-8{margin-left:33.3333333333%}.x-col-7{width:29.1666666667%}.x-col-offset-7{margin-left:29.1666666667%}.x-col-6{width:25%}.x-col-offset-6{margin-left:25%}.x-col-5{width:20.8333333333%}.x-col-offset-5{margin-left:20.8333333333%}.x-col-4{width:16.6666666667%}.x-col-offset-4{margin-left:16.6666666667%}.x-col-3{width:12.5%}.x-col-offset-3{margin-left:12.5%}.x-col-2{width:8.3333333333%}.x-col-offset-2{margin-left:8.3333333333%}.x-col-1{width:4.1666666667%}.x-col-offset-1{margin-left:4.1666666667%}@media only screen and (max-width: 767px){.x-col-xs-24{width:100%}}@media only screen and (max-width: 767px){.x-col-xs-23{width:95.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-22{width:91.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-21{width:87.5%}}@media only screen and (max-width: 767px){.x-col-xs-20{width:83.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-19{width:79.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-18{width:75%}}@media only screen and (max-width: 767px){.x-col-xs-17{width:70.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-16{width:66.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-15{width:62.5%}}@media only screen and (max-width: 767px){.x-col-xs-14{width:58.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-13{width:54.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-12{width:50%}}@media only screen and (max-width: 767px){.x-col-xs-11{width:45.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-10{width:41.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-9{width:37.5%}}@media only screen and (max-width: 767px){.x-col-xs-8{width:33.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-7{width:29.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-6{width:25%}}@media only screen and (max-width: 767px){.x-col-xs-5{width:20.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-4{width:16.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-3{width:12.5%}}@media only screen and (max-width: 767px){.x-col-xs-2{width:8.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-1{width:4.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-24{width:100%}}@media only screen and (min-width: 768px){.x-col-sm-23{width:95.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-22{width:91.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-21{width:87.5%}}@media only screen and (min-width: 768px){.x-col-sm-20{width:83.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-19{width:79.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-18{width:75%}}@media only screen and (min-width: 768px){.x-col-sm-17{width:70.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-16{width:66.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-15{width:62.5%}}@media only screen and (min-width: 768px){.x-col-sm-14{width:58.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-13{width:54.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-12{width:50%}}@media only screen and (min-width: 768px){.x-col-sm-11{width:45.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-10{width:41.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-9{width:37.5%}}@media only screen and (min-width: 768px){.x-col-sm-8{width:33.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-7{width:29.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-6{width:25%}}@media only screen and (min-width: 768px){.x-col-sm-5{width:20.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-4{width:16.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-3{width:12.5%}}@media only screen and (min-width: 768px){.x-col-sm-2{width:8.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-1{width:4.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-24{width:100%}}@media only screen and (min-width: 992px){.x-col-md-23{width:95.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-22{width:91.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-21{width:87.5%}}@media only screen and (min-width: 992px){.x-col-md-20{width:83.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-19{width:79.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-18{width:75%}}@media only screen and (min-width: 992px){.x-col-md-17{width:70.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-16{width:66.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-15{width:62.5%}}@media only screen and (min-width: 992px){.x-col-md-14{width:58.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-13{width:54.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-12{width:50%}}@media only screen and (min-width: 992px){.x-col-md-11{width:45.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-10{width:41.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-9{width:37.5%}}@media only screen and (min-width: 992px){.x-col-md-8{width:33.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-7{width:29.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-6{width:25%}}@media only screen and (min-width: 992px){.x-col-md-5{width:20.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-4{width:16.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-3{width:12.5%}}@media only screen and (min-width: 992px){.x-col-md-2{width:8.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-1{width:4.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-24{width:100%}}@media only screen and (min-width: 1200px){.x-col-lg-23{width:95.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-22{width:91.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-21{width:87.5%}}@media only screen and (min-width: 1200px){.x-col-lg-20{width:83.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-19{width:79.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-18{width:75%}}@media only screen and (min-width: 1200px){.x-col-lg-17{width:70.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-16{width:66.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-15{width:62.5%}}@media only screen and (min-width: 1200px){.x-col-lg-14{width:58.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-13{width:54.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-12{width:50%}}@media only screen and (min-width: 1200px){.x-col-lg-11{width:45.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-10{width:41.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-9{width:37.5%}}@media only screen and (min-width: 1200px){.x-col-lg-8{width:33.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-7{width:29.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-6{width:25%}}@media only screen and (min-width: 1200px){.x-col-lg-5{width:20.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-4{width:16.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-3{width:12.5%}}@media only screen and (min-width: 1200px){.x-col-lg-2{width:8.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-1{width:4.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-24{width:100%}}@media only screen and (min-width: 1920px){.x-col-xl-23{width:95.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-22{width:91.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-21{width:87.5%}}@media only screen and (min-width: 1920px){.x-col-xl-20{width:83.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-19{width:79.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-18{width:75%}}@media only screen and (min-width: 1920px){.x-col-xl-17{width:70.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-16{width:66.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-15{width:62.5%}}@media only screen and (min-width: 1920px){.x-col-xl-14{width:58.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-13{width:54.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-12{width:50%}}@media only screen and (min-width: 1920px){.x-col-xl-11{width:45.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-10{width:41.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-9{width:37.5%}}@media only screen and (min-width: 1920px){.x-col-xl-8{width:33.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-7{width:29.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-6{width:25%}}@media only screen and (min-width: 1920px){.x-col-xl-5{width:20.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-4{width:16.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-3{width:12.5%}}@media only screen and (min-width: 1920px){.x-col-xl-2{width:8.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-1{width:4.1666666667%}}.x-col-inherit{width:inherit}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
244
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XColComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
245
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.2.4", type: XColComponent, isStandalone: true, selector: "x-col", host: { properties: { "class.x-col-24": "this.getFlex", "class": "this.cls", "style.paddingLeft": "this.paddingLeft", "style.paddingRight": "this.paddingRight" } }, usesInheritance: true, ngImport: i0, template: '<ng-content></ng-content>', isInline: true, styles: [".x-col{position:relative;float:left;display:block;width:100%;box-sizing:border-box}.x-col-24{width:100%}.x-col-offset-24{margin-left:100%}.x-col-23{width:95.8333333333%}.x-col-offset-23{margin-left:95.8333333333%}.x-col-22{width:91.6666666667%}.x-col-offset-22{margin-left:91.6666666667%}.x-col-21{width:87.5%}.x-col-offset-21{margin-left:87.5%}.x-col-20{width:83.3333333333%}.x-col-offset-20{margin-left:83.3333333333%}.x-col-19{width:79.1666666667%}.x-col-offset-19{margin-left:79.1666666667%}.x-col-18{width:75%}.x-col-offset-18{margin-left:75%}.x-col-17{width:70.8333333333%}.x-col-offset-17{margin-left:70.8333333333%}.x-col-16{width:66.6666666667%}.x-col-offset-16{margin-left:66.6666666667%}.x-col-15{width:62.5%}.x-col-offset-15{margin-left:62.5%}.x-col-14{width:58.3333333333%}.x-col-offset-14{margin-left:58.3333333333%}.x-col-13{width:54.1666666667%}.x-col-offset-13{margin-left:54.1666666667%}.x-col-12{width:50%}.x-col-offset-12{margin-left:50%}.x-col-11{width:45.8333333333%}.x-col-offset-11{margin-left:45.8333333333%}.x-col-10{width:41.6666666667%}.x-col-offset-10{margin-left:41.6666666667%}.x-col-9{width:37.5%}.x-col-offset-9{margin-left:37.5%}.x-col-8{width:33.3333333333%}.x-col-offset-8{margin-left:33.3333333333%}.x-col-7{width:29.1666666667%}.x-col-offset-7{margin-left:29.1666666667%}.x-col-6{width:25%}.x-col-offset-6{margin-left:25%}.x-col-5{width:20.8333333333%}.x-col-offset-5{margin-left:20.8333333333%}.x-col-4{width:16.6666666667%}.x-col-offset-4{margin-left:16.6666666667%}.x-col-3{width:12.5%}.x-col-offset-3{margin-left:12.5%}.x-col-2{width:8.3333333333%}.x-col-offset-2{margin-left:8.3333333333%}.x-col-1{width:4.1666666667%}.x-col-offset-1{margin-left:4.1666666667%}@media only screen and (max-width: 767px){.x-col-xs-24{width:100%}}@media only screen and (max-width: 767px){.x-col-xs-23{width:95.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-22{width:91.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-21{width:87.5%}}@media only screen and (max-width: 767px){.x-col-xs-20{width:83.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-19{width:79.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-18{width:75%}}@media only screen and (max-width: 767px){.x-col-xs-17{width:70.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-16{width:66.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-15{width:62.5%}}@media only screen and (max-width: 767px){.x-col-xs-14{width:58.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-13{width:54.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-12{width:50%}}@media only screen and (max-width: 767px){.x-col-xs-11{width:45.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-10{width:41.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-9{width:37.5%}}@media only screen and (max-width: 767px){.x-col-xs-8{width:33.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-7{width:29.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-6{width:25%}}@media only screen and (max-width: 767px){.x-col-xs-5{width:20.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-4{width:16.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-3{width:12.5%}}@media only screen and (max-width: 767px){.x-col-xs-2{width:8.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-1{width:4.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-24{width:100%}}@media only screen and (min-width: 768px){.x-col-sm-23{width:95.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-22{width:91.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-21{width:87.5%}}@media only screen and (min-width: 768px){.x-col-sm-20{width:83.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-19{width:79.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-18{width:75%}}@media only screen and (min-width: 768px){.x-col-sm-17{width:70.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-16{width:66.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-15{width:62.5%}}@media only screen and (min-width: 768px){.x-col-sm-14{width:58.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-13{width:54.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-12{width:50%}}@media only screen and (min-width: 768px){.x-col-sm-11{width:45.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-10{width:41.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-9{width:37.5%}}@media only screen and (min-width: 768px){.x-col-sm-8{width:33.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-7{width:29.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-6{width:25%}}@media only screen and (min-width: 768px){.x-col-sm-5{width:20.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-4{width:16.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-3{width:12.5%}}@media only screen and (min-width: 768px){.x-col-sm-2{width:8.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-1{width:4.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-24{width:100%}}@media only screen and (min-width: 992px){.x-col-md-23{width:95.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-22{width:91.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-21{width:87.5%}}@media only screen and (min-width: 992px){.x-col-md-20{width:83.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-19{width:79.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-18{width:75%}}@media only screen and (min-width: 992px){.x-col-md-17{width:70.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-16{width:66.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-15{width:62.5%}}@media only screen and (min-width: 992px){.x-col-md-14{width:58.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-13{width:54.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-12{width:50%}}@media only screen and (min-width: 992px){.x-col-md-11{width:45.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-10{width:41.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-9{width:37.5%}}@media only screen and (min-width: 992px){.x-col-md-8{width:33.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-7{width:29.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-6{width:25%}}@media only screen and (min-width: 992px){.x-col-md-5{width:20.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-4{width:16.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-3{width:12.5%}}@media only screen and (min-width: 992px){.x-col-md-2{width:8.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-1{width:4.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-24{width:100%}}@media only screen and (min-width: 1200px){.x-col-lg-23{width:95.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-22{width:91.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-21{width:87.5%}}@media only screen and (min-width: 1200px){.x-col-lg-20{width:83.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-19{width:79.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-18{width:75%}}@media only screen and (min-width: 1200px){.x-col-lg-17{width:70.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-16{width:66.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-15{width:62.5%}}@media only screen and (min-width: 1200px){.x-col-lg-14{width:58.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-13{width:54.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-12{width:50%}}@media only screen and (min-width: 1200px){.x-col-lg-11{width:45.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-10{width:41.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-9{width:37.5%}}@media only screen and (min-width: 1200px){.x-col-lg-8{width:33.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-7{width:29.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-6{width:25%}}@media only screen and (min-width: 1200px){.x-col-lg-5{width:20.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-4{width:16.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-3{width:12.5%}}@media only screen and (min-width: 1200px){.x-col-lg-2{width:8.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-1{width:4.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-24{width:100%}}@media only screen and (min-width: 1920px){.x-col-xl-23{width:95.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-22{width:91.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-21{width:87.5%}}@media only screen and (min-width: 1920px){.x-col-xl-20{width:83.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-19{width:79.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-18{width:75%}}@media only screen and (min-width: 1920px){.x-col-xl-17{width:70.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-16{width:66.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-15{width:62.5%}}@media only screen and (min-width: 1920px){.x-col-xl-14{width:58.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-13{width:54.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-12{width:50%}}@media only screen and (min-width: 1920px){.x-col-xl-11{width:45.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-10{width:41.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-9{width:37.5%}}@media only screen and (min-width: 1920px){.x-col-xl-8{width:33.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-7{width:29.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-6{width:25%}}@media only screen and (min-width: 1920px){.x-col-xl-5{width:20.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-4{width:16.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-3{width:12.5%}}@media only screen and (min-width: 1920px){.x-col-xl-2{width:8.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-1{width:4.1666666667%}}.x-col-inherit{width:inherit}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
246
246
|
}
|
|
247
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
247
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XColComponent, decorators: [{
|
|
248
248
|
type: Component,
|
|
249
249
|
args: [{ selector: `${XColPrefix}`, template: '<ng-content></ng-content>', encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, styles: [".x-col{position:relative;float:left;display:block;width:100%;box-sizing:border-box}.x-col-24{width:100%}.x-col-offset-24{margin-left:100%}.x-col-23{width:95.8333333333%}.x-col-offset-23{margin-left:95.8333333333%}.x-col-22{width:91.6666666667%}.x-col-offset-22{margin-left:91.6666666667%}.x-col-21{width:87.5%}.x-col-offset-21{margin-left:87.5%}.x-col-20{width:83.3333333333%}.x-col-offset-20{margin-left:83.3333333333%}.x-col-19{width:79.1666666667%}.x-col-offset-19{margin-left:79.1666666667%}.x-col-18{width:75%}.x-col-offset-18{margin-left:75%}.x-col-17{width:70.8333333333%}.x-col-offset-17{margin-left:70.8333333333%}.x-col-16{width:66.6666666667%}.x-col-offset-16{margin-left:66.6666666667%}.x-col-15{width:62.5%}.x-col-offset-15{margin-left:62.5%}.x-col-14{width:58.3333333333%}.x-col-offset-14{margin-left:58.3333333333%}.x-col-13{width:54.1666666667%}.x-col-offset-13{margin-left:54.1666666667%}.x-col-12{width:50%}.x-col-offset-12{margin-left:50%}.x-col-11{width:45.8333333333%}.x-col-offset-11{margin-left:45.8333333333%}.x-col-10{width:41.6666666667%}.x-col-offset-10{margin-left:41.6666666667%}.x-col-9{width:37.5%}.x-col-offset-9{margin-left:37.5%}.x-col-8{width:33.3333333333%}.x-col-offset-8{margin-left:33.3333333333%}.x-col-7{width:29.1666666667%}.x-col-offset-7{margin-left:29.1666666667%}.x-col-6{width:25%}.x-col-offset-6{margin-left:25%}.x-col-5{width:20.8333333333%}.x-col-offset-5{margin-left:20.8333333333%}.x-col-4{width:16.6666666667%}.x-col-offset-4{margin-left:16.6666666667%}.x-col-3{width:12.5%}.x-col-offset-3{margin-left:12.5%}.x-col-2{width:8.3333333333%}.x-col-offset-2{margin-left:8.3333333333%}.x-col-1{width:4.1666666667%}.x-col-offset-1{margin-left:4.1666666667%}@media only screen and (max-width: 767px){.x-col-xs-24{width:100%}}@media only screen and (max-width: 767px){.x-col-xs-23{width:95.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-22{width:91.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-21{width:87.5%}}@media only screen and (max-width: 767px){.x-col-xs-20{width:83.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-19{width:79.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-18{width:75%}}@media only screen and (max-width: 767px){.x-col-xs-17{width:70.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-16{width:66.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-15{width:62.5%}}@media only screen and (max-width: 767px){.x-col-xs-14{width:58.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-13{width:54.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-12{width:50%}}@media only screen and (max-width: 767px){.x-col-xs-11{width:45.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-10{width:41.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-9{width:37.5%}}@media only screen and (max-width: 767px){.x-col-xs-8{width:33.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-7{width:29.1666666667%}}@media only screen and (max-width: 767px){.x-col-xs-6{width:25%}}@media only screen and (max-width: 767px){.x-col-xs-5{width:20.8333333333%}}@media only screen and (max-width: 767px){.x-col-xs-4{width:16.6666666667%}}@media only screen and (max-width: 767px){.x-col-xs-3{width:12.5%}}@media only screen and (max-width: 767px){.x-col-xs-2{width:8.3333333333%}}@media only screen and (max-width: 767px){.x-col-xs-1{width:4.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-24{width:100%}}@media only screen and (min-width: 768px){.x-col-sm-23{width:95.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-22{width:91.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-21{width:87.5%}}@media only screen and (min-width: 768px){.x-col-sm-20{width:83.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-19{width:79.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-18{width:75%}}@media only screen and (min-width: 768px){.x-col-sm-17{width:70.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-16{width:66.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-15{width:62.5%}}@media only screen and (min-width: 768px){.x-col-sm-14{width:58.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-13{width:54.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-12{width:50%}}@media only screen and (min-width: 768px){.x-col-sm-11{width:45.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-10{width:41.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-9{width:37.5%}}@media only screen and (min-width: 768px){.x-col-sm-8{width:33.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-7{width:29.1666666667%}}@media only screen and (min-width: 768px){.x-col-sm-6{width:25%}}@media only screen and (min-width: 768px){.x-col-sm-5{width:20.8333333333%}}@media only screen and (min-width: 768px){.x-col-sm-4{width:16.6666666667%}}@media only screen and (min-width: 768px){.x-col-sm-3{width:12.5%}}@media only screen and (min-width: 768px){.x-col-sm-2{width:8.3333333333%}}@media only screen and (min-width: 768px){.x-col-sm-1{width:4.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-24{width:100%}}@media only screen and (min-width: 992px){.x-col-md-23{width:95.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-22{width:91.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-21{width:87.5%}}@media only screen and (min-width: 992px){.x-col-md-20{width:83.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-19{width:79.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-18{width:75%}}@media only screen and (min-width: 992px){.x-col-md-17{width:70.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-16{width:66.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-15{width:62.5%}}@media only screen and (min-width: 992px){.x-col-md-14{width:58.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-13{width:54.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-12{width:50%}}@media only screen and (min-width: 992px){.x-col-md-11{width:45.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-10{width:41.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-9{width:37.5%}}@media only screen and (min-width: 992px){.x-col-md-8{width:33.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-7{width:29.1666666667%}}@media only screen and (min-width: 992px){.x-col-md-6{width:25%}}@media only screen and (min-width: 992px){.x-col-md-5{width:20.8333333333%}}@media only screen and (min-width: 992px){.x-col-md-4{width:16.6666666667%}}@media only screen and (min-width: 992px){.x-col-md-3{width:12.5%}}@media only screen and (min-width: 992px){.x-col-md-2{width:8.3333333333%}}@media only screen and (min-width: 992px){.x-col-md-1{width:4.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-24{width:100%}}@media only screen and (min-width: 1200px){.x-col-lg-23{width:95.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-22{width:91.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-21{width:87.5%}}@media only screen and (min-width: 1200px){.x-col-lg-20{width:83.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-19{width:79.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-18{width:75%}}@media only screen and (min-width: 1200px){.x-col-lg-17{width:70.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-16{width:66.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-15{width:62.5%}}@media only screen and (min-width: 1200px){.x-col-lg-14{width:58.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-13{width:54.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-12{width:50%}}@media only screen and (min-width: 1200px){.x-col-lg-11{width:45.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-10{width:41.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-9{width:37.5%}}@media only screen and (min-width: 1200px){.x-col-lg-8{width:33.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-7{width:29.1666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-6{width:25%}}@media only screen and (min-width: 1200px){.x-col-lg-5{width:20.8333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-4{width:16.6666666667%}}@media only screen and (min-width: 1200px){.x-col-lg-3{width:12.5%}}@media only screen and (min-width: 1200px){.x-col-lg-2{width:8.3333333333%}}@media only screen and (min-width: 1200px){.x-col-lg-1{width:4.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-24{width:100%}}@media only screen and (min-width: 1920px){.x-col-xl-23{width:95.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-22{width:91.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-21{width:87.5%}}@media only screen and (min-width: 1920px){.x-col-xl-20{width:83.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-19{width:79.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-18{width:75%}}@media only screen and (min-width: 1920px){.x-col-xl-17{width:70.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-16{width:66.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-15{width:62.5%}}@media only screen and (min-width: 1920px){.x-col-xl-14{width:58.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-13{width:54.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-12{width:50%}}@media only screen and (min-width: 1920px){.x-col-xl-11{width:45.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-10{width:41.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-9{width:37.5%}}@media only screen and (min-width: 1920px){.x-col-xl-8{width:33.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-7{width:29.1666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-6{width:25%}}@media only screen and (min-width: 1920px){.x-col-xl-5{width:20.8333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-4{width:16.6666666667%}}@media only screen and (min-width: 1920px){.x-col-xl-3{width:12.5%}}@media only screen and (min-width: 1920px){.x-col-xl-2{width:8.3333333333%}}@media only screen and (min-width: 1920px){.x-col-xl-1{width:4.1666666667%}}.x-col-inherit{width:inherit}\n"] }]
|
|
250
250
|
}], propDecorators: { getFlex: [{
|
|
@@ -262,11 +262,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.0", ngImpor
|
|
|
262
262
|
}] } });
|
|
263
263
|
|
|
264
264
|
class XLayoutModule {
|
|
265
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
266
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.
|
|
267
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.
|
|
265
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLayoutModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
266
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.2.4", ngImport: i0, type: XLayoutModule, imports: [XRowComponent, XColComponent], exports: [XRowComponent, XColComponent] }); }
|
|
267
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLayoutModule }); }
|
|
268
268
|
}
|
|
269
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
269
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLayoutModule, decorators: [{
|
|
270
270
|
type: NgModule,
|
|
271
271
|
args: [{
|
|
272
272
|
exports: [XRowComponent, XColComponent],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-nest-ui-layout.mjs","sources":["../../../../lib/ng-nest/ui/layout/layout.property.ts","../../../../lib/ng-nest/ui/layout/row.component.ts","../../../../lib/ng-nest/ui/layout/col.component.ts","../../../../lib/ng-nest/ui/layout/layout.module.ts","../../../../lib/ng-nest/ui/layout/ng-nest-ui-layout.ts"],"sourcesContent":["import { XPropertyFunction, XToBoolean, XToCssPixelValue, XToNumber } from '@ng-nest/ui/core';\r\nimport { Component, input } from '@angular/core';\r\nimport type { XJustify, XAlign, XNumber, XBoolean } from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Row\r\n * @selector x-row\r\n * @decorator component\r\n */\r\nexport const XRowPrefix = 'x-row';\r\nconst X_ROW_CONFIG_NAME = 'row';\r\n\r\n/**\r\n * Row Property\r\n */\r\n@Component({ selector: `${XRowPrefix}-property`, template: '' })\r\nexport class XRowProperty extends XPropertyFunction(X_ROW_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 列间隔\r\n * @en_US Column interval\r\n * @example\r\n *\r\n * ```html\r\n * <x-row space=\"1rem\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly space = input<string, XNumber>('', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN flex 布局下的水平排列方式\r\n * @en_US Horizontal arrangement under flex layout\r\n * @example\r\n *\r\n * ```html\r\n * <x-row justify=\"end\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly justify = input<XJustify>();\r\n /**\r\n * @zh_CN flex 布局下的垂直排列方式\r\n * @en_US Vertical arrangement under flex layout\r\n * @example\r\n *\r\n * ```html\r\n * <x-row align=\"end\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly align = input<XAlign>();\r\n}\r\n\r\n/**\r\n * Col\r\n * @selector x-col\r\n * @decorator component\r\n */\r\nexport const XColPrefix = 'x-col';\r\nconst X_COL_CONFIG_NAME = 'col';\r\n\r\n/**\r\n * Col Property\r\n */\r\n@Component({ selector: `${XColPrefix}-property`, template: '' })\r\nexport class XColProperty extends XPropertyFunction(X_COL_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 24栅格布局,列占的宽度\r\n * @en_US 24 grid layout, column width\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"18\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly span = input<number, XNumber>(24, { transform: XToNumber });\r\n /**\r\n * @zh_CN 栅格左侧的间隔格数\r\n * @en_US The number of intervals on the left side of the grid\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"12\" offset=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly offset = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * <768px\r\n */\r\n readonly xs = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥768px\r\n */\r\n readonly sm = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥992px\r\n */\r\n readonly md = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥1200px\r\n */\r\n readonly lg = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥1920px\r\n */\r\n readonly xl = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * @zh_CN 默认样式\r\n * @en_US Default style\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\" inherit>col-1</x-col>\r\n * <x-col span=\"12\" offset=\"6\" inherit>col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly inherit = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n}\r\n","import { Component, ViewEncapsulation, ChangeDetectionStrategy, HostBinding, inject, computed } from '@angular/core';\r\nimport { XRowPrefix, XRowProperty } from './layout.property';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { XComputedStyle, XToCssPx } from '@ng-nest/ui/core';\r\n\r\n@Component({\r\n selector: `${XRowPrefix}`,\r\n template: '<ng-content></ng-content>',\r\n styleUrls: ['./row.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XRowComponent extends XRowProperty {\r\n private document: Document = inject(DOCUMENT);\r\n private fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));\r\n @HostBinding(`class.x-flex`) get getFlex() {\r\n return this.justify() || this.align() ? true : false;\r\n }\r\n @HostBinding('class') get cls() {\r\n let cls: string[] = [XRowPrefix];\r\n if (this.justify()) cls.push(`x-justify-${this.justify()}`);\r\n if (this.align()) cls.push(`x-align-${this.align()}`);\r\n return cls.join(' ');\r\n }\r\n @HostBinding('style.marginLeft') get marginLeft() {\r\n return `-${this.spaceSignal() / 2}px`;\r\n }\r\n @HostBinding('style.marginRight') get marginRight() {\r\n return `-${this.spaceSignal() / 2}px`;\r\n }\r\n\r\n spaceSignal = computed(() => {\r\n if (!this.space()) return 0;\r\n const space = this.space();\r\n return XToCssPx(space, this.fontSize());\r\n });\r\n}\r\n","import { Component, ViewEncapsulation, ChangeDetectionStrategy, HostBinding, inject, computed } from '@angular/core';\r\nimport { XColPrefix, XColProperty } from './layout.property';\r\nimport { XRowComponent } from './row.component';\r\nimport { XComputedStyle, XToCssPx } from '@ng-nest/ui/core';\r\nimport { DOCUMENT } from '@angular/common';\r\n\r\n@Component({\r\n selector: `${XColPrefix}`,\r\n template: '<ng-content></ng-content>',\r\n styleUrls: ['./col.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XColComponent extends XColProperty {\r\n private rowComponent = inject(XRowComponent, { optional: true, host: true });\r\n private document: Document = inject(DOCUMENT);\r\n private fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));\r\n @HostBinding(`class.x-col-24`) get getFlex() {\r\n return this.xs() || this.sm() || this.md() || this.lg() || this.xl() || this.span() == 24 ? true : false;\r\n }\r\n @HostBinding('class') get cls() {\r\n let cls: string[] = [XColPrefix];\r\n if (this.span()) cls.push(`${XColPrefix}-${this.span()}`);\r\n if (this.offset()) cls.push(`${XColPrefix}-offset-${this.offset()}`);\r\n if (this.xs()) cls.push(`${XColPrefix}-xs-${this.xs()}`);\r\n if (this.sm()) cls.push(`${XColPrefix}-sm-${this.sm()}`);\r\n if (this.md()) cls.push(`${XColPrefix}-md-${this.md()}`);\r\n if (this.lg()) cls.push(`${XColPrefix}-lg-${this.lg()}`);\r\n if (this.xl()) cls.push(`${XColPrefix}-xl-${this.xl()}`);\r\n if (this.inherit()) cls.push(`${XColPrefix}-inherit`);\r\n return cls.join(' ');\r\n }\r\n @HostBinding('style.paddingLeft') get paddingLeft() {\r\n return `${this.space() / 2}px`;\r\n }\r\n @HostBinding('style.paddingRight') get paddingRight() {\r\n return `${this.space() / 2}px`;\r\n }\r\n\r\n space = computed(() => {\r\n if (!this.rowComponent?.space()) return 0;\r\n const space = this.rowComponent.space();\r\n return XToCssPx(space, this.fontSize());\r\n });\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { XRowComponent } from './row.component';\r\nimport { XColComponent } from './col.component';\r\n\r\n@NgModule({\r\n exports: [XRowComponent, XColComponent],\r\n imports: [XRowComponent, XColComponent]\r\n})\r\nexport class XLayoutModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAIA;;;;AAIG;AACI,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ng-nest/ui/layout/col.component.ts","../../../../lib/ng-nest/ui/layout/layout.module.ts","../../../../lib/ng-nest/ui/layout/ng-nest-ui-layout.ts"],"sourcesContent":["import { XPropertyFunction, XToBoolean, XToCssPixelValue, XToNumber } from '@ng-nest/ui/core';\r\nimport { Component, input } from '@angular/core';\r\nimport type { XJustify, XAlign, XNumber, XBoolean } from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Row\r\n * @selector x-row\r\n * @decorator component\r\n */\r\nexport const XRowPrefix = 'x-row';\r\nconst X_ROW_CONFIG_NAME = 'row';\r\n\r\n/**\r\n * Row Property\r\n */\r\n@Component({ selector: `${XRowPrefix}-property`, template: '' })\r\nexport class XRowProperty extends XPropertyFunction(X_ROW_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 列间隔\r\n * @en_US Column interval\r\n * @example\r\n *\r\n * ```html\r\n * <x-row space=\"1rem\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly space = input<string, XNumber>('', { transform: XToCssPixelValue });\r\n /**\r\n * @zh_CN flex 布局下的水平排列方式\r\n * @en_US Horizontal arrangement under flex layout\r\n * @example\r\n *\r\n * ```html\r\n * <x-row justify=\"end\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly justify = input<XJustify>();\r\n /**\r\n * @zh_CN flex 布局下的垂直排列方式\r\n * @en_US Vertical arrangement under flex layout\r\n * @example\r\n *\r\n * ```html\r\n * <x-row align=\"end\">\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly align = input<XAlign>();\r\n}\r\n\r\n/**\r\n * Col\r\n * @selector x-col\r\n * @decorator component\r\n */\r\nexport const XColPrefix = 'x-col';\r\nconst X_COL_CONFIG_NAME = 'col';\r\n\r\n/**\r\n * Col Property\r\n */\r\n@Component({ selector: `${XColPrefix}-property`, template: '' })\r\nexport class XColProperty extends XPropertyFunction(X_COL_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 24栅格布局,列占的宽度\r\n * @en_US 24 grid layout, column width\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"18\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly span = input<number, XNumber>(24, { transform: XToNumber });\r\n /**\r\n * @zh_CN 栅格左侧的间隔格数\r\n * @en_US The number of intervals on the left side of the grid\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\">col-1</x-col>\r\n * <x-col span=\"12\" offset=\"6\">col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly offset = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * <768px\r\n */\r\n readonly xs = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥768px\r\n */\r\n readonly sm = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥992px\r\n */\r\n readonly md = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥1200px\r\n */\r\n readonly lg = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * ≥1920px\r\n */\r\n readonly xl = input<number, XNumber>(0, { transform: XToNumber });\r\n /**\r\n * @zh_CN 默认样式\r\n * @en_US Default style\r\n * @example\r\n *\r\n * ```html\r\n * <x-row>\r\n * <x-col span=\"6\" inherit>col-1</x-col>\r\n * <x-col span=\"12\" offset=\"6\" inherit>col-2</x-col>\r\n * </x-row>\r\n * ```\r\n *\r\n */\r\n readonly inherit = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n}\r\n","import { Component, ViewEncapsulation, ChangeDetectionStrategy, HostBinding, inject, computed } from '@angular/core';\r\nimport { XRowPrefix, XRowProperty } from './layout.property';\r\nimport { DOCUMENT } from '@angular/common';\r\nimport { XComputedStyle, XToCssPx } from '@ng-nest/ui/core';\r\n\r\n@Component({\r\n selector: `${XRowPrefix}`,\r\n template: '<ng-content></ng-content>',\r\n styleUrls: ['./row.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XRowComponent extends XRowProperty {\r\n private document: Document = inject(DOCUMENT);\r\n private fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));\r\n @HostBinding(`class.x-flex`) get getFlex() {\r\n return this.justify() || this.align() ? true : false;\r\n }\r\n @HostBinding('class') get cls() {\r\n let cls: string[] = [XRowPrefix];\r\n if (this.justify()) cls.push(`x-justify-${this.justify()}`);\r\n if (this.align()) cls.push(`x-align-${this.align()}`);\r\n return cls.join(' ');\r\n }\r\n @HostBinding('style.marginLeft') get marginLeft() {\r\n return `-${this.spaceSignal() / 2}px`;\r\n }\r\n @HostBinding('style.marginRight') get marginRight() {\r\n return `-${this.spaceSignal() / 2}px`;\r\n }\r\n\r\n spaceSignal = computed(() => {\r\n if (!this.space()) return 0;\r\n const space = this.space();\r\n return XToCssPx(space, this.fontSize());\r\n });\r\n}\r\n","import { Component, ViewEncapsulation, ChangeDetectionStrategy, HostBinding, inject, computed } from '@angular/core';\r\nimport { XColPrefix, XColProperty } from './layout.property';\r\nimport { XRowComponent } from './row.component';\r\nimport { XComputedStyle, XToCssPx } from '@ng-nest/ui/core';\r\nimport { DOCUMENT } from '@angular/common';\r\n\r\n@Component({\r\n selector: `${XColPrefix}`,\r\n template: '<ng-content></ng-content>',\r\n styleUrls: ['./col.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XColComponent extends XColProperty {\r\n private rowComponent = inject(XRowComponent, { optional: true, host: true });\r\n private document: Document = inject(DOCUMENT);\r\n private fontSize = computed(() => parseFloat(XComputedStyle(this.document.documentElement, 'font-size')));\r\n @HostBinding(`class.x-col-24`) get getFlex() {\r\n return this.xs() || this.sm() || this.md() || this.lg() || this.xl() || this.span() == 24 ? true : false;\r\n }\r\n @HostBinding('class') get cls() {\r\n let cls: string[] = [XColPrefix];\r\n if (this.span()) cls.push(`${XColPrefix}-${this.span()}`);\r\n if (this.offset()) cls.push(`${XColPrefix}-offset-${this.offset()}`);\r\n if (this.xs()) cls.push(`${XColPrefix}-xs-${this.xs()}`);\r\n if (this.sm()) cls.push(`${XColPrefix}-sm-${this.sm()}`);\r\n if (this.md()) cls.push(`${XColPrefix}-md-${this.md()}`);\r\n if (this.lg()) cls.push(`${XColPrefix}-lg-${this.lg()}`);\r\n if (this.xl()) cls.push(`${XColPrefix}-xl-${this.xl()}`);\r\n if (this.inherit()) cls.push(`${XColPrefix}-inherit`);\r\n return cls.join(' ');\r\n }\r\n @HostBinding('style.paddingLeft') get paddingLeft() {\r\n return `${this.space() / 2}px`;\r\n }\r\n @HostBinding('style.paddingRight') get paddingRight() {\r\n return `${this.space() / 2}px`;\r\n }\r\n\r\n space = computed(() => {\r\n if (!this.rowComponent?.space()) return 0;\r\n const space = this.rowComponent.space();\r\n return XToCssPx(space, this.fontSize());\r\n });\r\n}\r\n","import { NgModule } from '@angular/core';\r\nimport { XRowComponent } from './row.component';\r\nimport { XColComponent } from './col.component';\r\n\r\n@NgModule({\r\n exports: [XRowComponent, XColComponent],\r\n imports: [XRowComponent, XColComponent]\r\n})\r\nexport class XLayoutModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAIA;;;;AAIG;AACI,MAAM,UAAU,GAAG;AAC1B,MAAM,iBAAiB,GAAG,KAAK;AAE/B;;AAEG;MAEU,YAAa,SAAQ,iBAAiB,CAAC,iBAAiB,CAAC,CAAA;AADtE,IAAA,WAAA,GAAA;;AAEE;;;;;;;;;;;;AAYG;AACM,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK,CAAkB,E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IAAA,EAAA,aAAa,YAFd,aAAa,EAAE,aAAa,CAAA,EAAA,OAAA,EAAA,CAD5B,aAAa,EAAE,aAAa,CAAA,EAAA,CAAA,CAAA;kIAG3B,aAAa,EAAA,CAAA,CAAA;;2FAAb,aAAa,EAAA,UAAA,EAAA,CAAA;kBAJzB,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,aAAa,CAAC;AACvC,oBAAA,OAAO,EAAE,CAAC,aAAa,EAAE,aAAa;AACvC,iBAAA;;;ACPD;;AAEG;;;;"}
|
|
@@ -27,7 +27,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
27
27
|
* ```
|
|
28
28
|
*
|
|
29
29
|
*/
|
|
30
|
-
this.href = input();
|
|
30
|
+
this.href = input(...(ngDevMode ? [undefined, { debugName: "href" }] : []));
|
|
31
31
|
/**
|
|
32
32
|
* @zh_CN 图标
|
|
33
33
|
* @en_US Icon
|
|
@@ -39,7 +39,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
39
39
|
* ```
|
|
40
40
|
*
|
|
41
41
|
*/
|
|
42
|
-
this.icon = input();
|
|
42
|
+
this.icon = input(...(ngDevMode ? [undefined, { debugName: "icon" }] : []));
|
|
43
43
|
/**
|
|
44
44
|
* @zh_CN 下划线
|
|
45
45
|
* @en_US Underscore
|
|
@@ -50,7 +50,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
50
50
|
* ```
|
|
51
51
|
*
|
|
52
52
|
*/
|
|
53
|
-
this.underline = input(this.config?.underline ?? false, { transform: XToBoolean });
|
|
53
|
+
this.underline = input(this.config?.underline ?? false, ...(ngDevMode ? [{ debugName: "underline", transform: XToBoolean }] : [{ transform: XToBoolean }]));
|
|
54
54
|
/**
|
|
55
55
|
* @zh_CN 禁用
|
|
56
56
|
* @en_US Disabled
|
|
@@ -61,7 +61,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
61
61
|
* ```
|
|
62
62
|
*
|
|
63
63
|
*/
|
|
64
|
-
this.disabled = input(false, { transform: XToBoolean });
|
|
64
|
+
this.disabled = input(false, ...(ngDevMode ? [{ debugName: "disabled", transform: XToBoolean }] : [{ transform: XToBoolean }]));
|
|
65
65
|
/**
|
|
66
66
|
* @zh_CN 图标靠右对齐
|
|
67
67
|
* @en_US Icons are aligned to the right
|
|
@@ -73,7 +73,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
73
73
|
* ```
|
|
74
74
|
*
|
|
75
75
|
*/
|
|
76
|
-
this.iconRight = input(this.config?.iconRight ?? false, { transform: XToBoolean });
|
|
76
|
+
this.iconRight = input(this.config?.iconRight ?? false, ...(ngDevMode ? [{ debugName: "iconRight", transform: XToBoolean }] : [{ transform: XToBoolean }]));
|
|
77
77
|
/**
|
|
78
78
|
* @zh_CN 链接类型
|
|
79
79
|
* @en_US Link type
|
|
@@ -88,7 +88,7 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
88
88
|
* ```
|
|
89
89
|
*
|
|
90
90
|
*/
|
|
91
|
-
this.type = input('initial');
|
|
91
|
+
this.type = input('initial', ...(ngDevMode ? [{ debugName: "type" }] : []));
|
|
92
92
|
/**
|
|
93
93
|
* @zh_CN 打开方式
|
|
94
94
|
* @en_US Open method
|
|
@@ -100,12 +100,12 @@ class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {
|
|
|
100
100
|
* ```
|
|
101
101
|
*
|
|
102
102
|
*/
|
|
103
|
-
this.target = input();
|
|
103
|
+
this.target = input(...(ngDevMode ? [undefined, { debugName: "target" }] : []));
|
|
104
104
|
}
|
|
105
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
106
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.
|
|
105
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkProperty, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
|
|
106
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.2.4", type: XLinkProperty, isStandalone: true, selector: "x-link-property", inputs: { href: { classPropertyName: "href", publicName: "href", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, underline: { classPropertyName: "underline", publicName: "underline", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null }, iconRight: { classPropertyName: "iconRight", publicName: "iconRight", isSignal: true, isRequired: false, transformFunction: null }, type: { classPropertyName: "type", publicName: "type", isSignal: true, isRequired: false, transformFunction: null }, target: { classPropertyName: "target", publicName: "target", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0, template: '', isInline: true }); }
|
|
107
107
|
}
|
|
108
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
108
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkProperty, decorators: [{
|
|
109
109
|
type: Component,
|
|
110
110
|
args: [{ selector: `${XLinkPrefix}-property`, template: '' }]
|
|
111
111
|
}] });
|
|
@@ -116,7 +116,7 @@ class XLinkComponent extends XLinkProperty {
|
|
|
116
116
|
this.link = viewChild.required('link');
|
|
117
117
|
this.classMap = computed(() => ({
|
|
118
118
|
[`${XLinkPrefix}-${this.type()}`]: !XIsEmpty(this.type())
|
|
119
|
-
}));
|
|
119
|
+
}), ...(ngDevMode ? [{ debugName: "classMap" }] : []));
|
|
120
120
|
this.renderer = inject(Renderer2);
|
|
121
121
|
effect(() => {
|
|
122
122
|
if (XIsEmpty(this.href()) && this.link()) {
|
|
@@ -124,20 +124,20 @@ class XLinkComponent extends XLinkProperty {
|
|
|
124
124
|
}
|
|
125
125
|
});
|
|
126
126
|
}
|
|
127
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
128
|
-
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.
|
|
127
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
128
|
+
/** @nocollapse */ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.2.4", type: XLinkComponent, isStandalone: true, selector: "x-link", viewQueries: [{ propertyName: "link", first: true, predicate: ["link"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<a\r\n #link\r\n class=\"x-link\"\r\n [ngClass]=\"classMap()\"\r\n [class.x-link-disabled]=\"disabled()\"\r\n [class.x-link-underline]=\"underline() && !disabled()\"\r\n [class.x-link-icon-right]=\"iconRight()\"\r\n [class.x-link-only-icon]=\"icon() && !content.innerHTML.trim()\"\r\n [attr.href]=\"href()\"\r\n [attr.target]=\"target()\"\r\n>\r\n @if (icon()) {\r\n <x-icon [type]=\"icon()\"></x-icon>\r\n }\r\n <span #content><ng-content></ng-content></span>\r\n</a>\r\n", styles: ["x-link{display:inline-flex}.x-link{margin:0;padding:0}.x-link{display:inline-flex;flex-direction:row;align-items:center;justify-content:center;vertical-align:middle;position:relative;text-decoration:none;outline:none;cursor:pointer;padding:0;transition:all var(--x-animation-duration-base) ease-in-out}.x-link>x-icon{margin-right:.125rem}.x-link-underline:hover:after{content:\"\";position:absolute;left:0;right:0;height:0;bottom:0;border-bottom:.0625rem solid var(--x-primary)}.x-link-icon-right{flex-direction:row-reverse}.x-link-icon-right>x-icon{margin-right:0;margin-left:.125rem}.x-link-only-icon>x-icon{margin-right:0;margin-left:0}.x-link-initial{color:var(--x-text)}.x-link-initial:hover{color:var(--x-primary)}.x-link-initial:hover:after{border-color:var(--x-primary)}.x-link-initial:active{color:var(--x-primary-a100)}.x-link-initial.x-link-disabled{color:var(--x-text-400);cursor:not-allowed}.x-link-initial.x-link-disabled:active{transform:none}.x-link-initial.x-link-disabled:hover:after{border-color:transparent}.x-link-primary{color:var(--x-primary)}.x-link-primary:hover{color:var(--x-primary-100)}.x-link-primary:hover:after{border-color:var(--x-primary-100)}.x-link-primary:active{color:var(--x-primary-300)}.x-link-primary.x-link-disabled{color:var(--x-primary-400);cursor:not-allowed}.x-link-primary.x-link-disabled:active{transform:none}.x-link-primary.x-link-disabled:hover:after{border-color:transparent}.x-link-success{color:var(--x-success)}.x-link-success:hover{color:var(--x-success-100)}.x-link-success:hover:after{border-color:var(--x-success-100)}.x-link-success:active{color:var(--x-success-300)}.x-link-success.x-link-disabled{color:var(--x-success-400);cursor:not-allowed}.x-link-success.x-link-disabled:active{transform:none}.x-link-success.x-link-disabled:hover:after{border-color:transparent}.x-link-warning{color:var(--x-warning)}.x-link-warning:hover{color:var(--x-warning-100)}.x-link-warning:hover:after{border-color:var(--x-warning-100)}.x-link-warning:active{color:var(--x-warning-300)}.x-link-warning.x-link-disabled{color:var(--x-warning-400);cursor:not-allowed}.x-link-warning.x-link-disabled:active{transform:none}.x-link-warning.x-link-disabled:hover:after{border-color:transparent}.x-link-danger{color:var(--x-danger)}.x-link-danger:hover{color:var(--x-danger-100)}.x-link-danger:hover:after{border-color:var(--x-danger-100)}.x-link-danger:active{color:var(--x-danger-300)}.x-link-danger.x-link-disabled{color:var(--x-danger-400);cursor:not-allowed}.x-link-danger.x-link-disabled:active{transform:none}.x-link-danger.x-link-disabled:hover:after{border-color:transparent}.x-link-info{color:var(--x-info)}.x-link-info:hover{color:var(--x-info-100)}.x-link-info:hover:after{border-color:var(--x-info-100)}.x-link-info:active{color:var(--x-info-300)}.x-link-info.x-link-disabled{color:var(--x-info-400);cursor:not-allowed}.x-link-info.x-link-disabled:active{transform:none}.x-link-info.x-link-disabled:hover:after{border-color:transparent}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "component", type: XIconComponent, selector: "x-icon" }], changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
|
|
129
129
|
}
|
|
130
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
130
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkComponent, decorators: [{
|
|
131
131
|
type: Component,
|
|
132
132
|
args: [{ selector: `${XLinkPrefix}`, imports: [NgClass, XIconComponent], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<a\r\n #link\r\n class=\"x-link\"\r\n [ngClass]=\"classMap()\"\r\n [class.x-link-disabled]=\"disabled()\"\r\n [class.x-link-underline]=\"underline() && !disabled()\"\r\n [class.x-link-icon-right]=\"iconRight()\"\r\n [class.x-link-only-icon]=\"icon() && !content.innerHTML.trim()\"\r\n [attr.href]=\"href()\"\r\n [attr.target]=\"target()\"\r\n>\r\n @if (icon()) {\r\n <x-icon [type]=\"icon()\"></x-icon>\r\n }\r\n <span #content><ng-content></ng-content></span>\r\n</a>\r\n", styles: ["x-link{display:inline-flex}.x-link{margin:0;padding:0}.x-link{display:inline-flex;flex-direction:row;align-items:center;justify-content:center;vertical-align:middle;position:relative;text-decoration:none;outline:none;cursor:pointer;padding:0;transition:all var(--x-animation-duration-base) ease-in-out}.x-link>x-icon{margin-right:.125rem}.x-link-underline:hover:after{content:\"\";position:absolute;left:0;right:0;height:0;bottom:0;border-bottom:.0625rem solid var(--x-primary)}.x-link-icon-right{flex-direction:row-reverse}.x-link-icon-right>x-icon{margin-right:0;margin-left:.125rem}.x-link-only-icon>x-icon{margin-right:0;margin-left:0}.x-link-initial{color:var(--x-text)}.x-link-initial:hover{color:var(--x-primary)}.x-link-initial:hover:after{border-color:var(--x-primary)}.x-link-initial:active{color:var(--x-primary-a100)}.x-link-initial.x-link-disabled{color:var(--x-text-400);cursor:not-allowed}.x-link-initial.x-link-disabled:active{transform:none}.x-link-initial.x-link-disabled:hover:after{border-color:transparent}.x-link-primary{color:var(--x-primary)}.x-link-primary:hover{color:var(--x-primary-100)}.x-link-primary:hover:after{border-color:var(--x-primary-100)}.x-link-primary:active{color:var(--x-primary-300)}.x-link-primary.x-link-disabled{color:var(--x-primary-400);cursor:not-allowed}.x-link-primary.x-link-disabled:active{transform:none}.x-link-primary.x-link-disabled:hover:after{border-color:transparent}.x-link-success{color:var(--x-success)}.x-link-success:hover{color:var(--x-success-100)}.x-link-success:hover:after{border-color:var(--x-success-100)}.x-link-success:active{color:var(--x-success-300)}.x-link-success.x-link-disabled{color:var(--x-success-400);cursor:not-allowed}.x-link-success.x-link-disabled:active{transform:none}.x-link-success.x-link-disabled:hover:after{border-color:transparent}.x-link-warning{color:var(--x-warning)}.x-link-warning:hover{color:var(--x-warning-100)}.x-link-warning:hover:after{border-color:var(--x-warning-100)}.x-link-warning:active{color:var(--x-warning-300)}.x-link-warning.x-link-disabled{color:var(--x-warning-400);cursor:not-allowed}.x-link-warning.x-link-disabled:active{transform:none}.x-link-warning.x-link-disabled:hover:after{border-color:transparent}.x-link-danger{color:var(--x-danger)}.x-link-danger:hover{color:var(--x-danger-100)}.x-link-danger:hover:after{border-color:var(--x-danger-100)}.x-link-danger:active{color:var(--x-danger-300)}.x-link-danger.x-link-disabled{color:var(--x-danger-400);cursor:not-allowed}.x-link-danger.x-link-disabled:active{transform:none}.x-link-danger.x-link-disabled:hover:after{border-color:transparent}.x-link-info{color:var(--x-info)}.x-link-info:hover{color:var(--x-info-100)}.x-link-info:hover:after{border-color:var(--x-info-100)}.x-link-info:active{color:var(--x-info-300)}.x-link-info.x-link-disabled{color:var(--x-info-400);cursor:not-allowed}.x-link-info.x-link-disabled:active{transform:none}.x-link-info.x-link-disabled:hover:after{border-color:transparent}\n"] }]
|
|
133
133
|
}], ctorParameters: () => [] });
|
|
134
134
|
|
|
135
135
|
class XLinkModule {
|
|
136
|
-
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.
|
|
137
|
-
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.
|
|
138
|
-
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.
|
|
136
|
+
/** @nocollapse */ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
137
|
+
/** @nocollapse */ static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "20.2.4", ngImport: i0, type: XLinkModule, imports: [XLinkComponent], exports: [XLinkComponent] }); }
|
|
138
|
+
/** @nocollapse */ static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkModule, imports: [XLinkComponent] }); }
|
|
139
139
|
}
|
|
140
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.
|
|
140
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.2.4", ngImport: i0, type: XLinkModule, decorators: [{
|
|
141
141
|
type: NgModule,
|
|
142
142
|
args: [{
|
|
143
143
|
exports: [XLinkComponent],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ng-nest-ui-link.mjs","sources":["../../../../lib/ng-nest/ui/link/link.property.ts","../../../../lib/ng-nest/ui/link/link.component.ts","../../../../lib/ng-nest/ui/link/link.component.html","../../../../lib/ng-nest/ui/link/link.module.ts","../../../../lib/ng-nest/ui/link/ng-nest-ui-link.ts"],"sourcesContent":["import { XPropertyFunction, XToBoolean } from '@ng-nest/ui/core';\r\nimport { Component, input } from '@angular/core';\r\nimport type { XBoolean, XType } from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Link\r\n * @selector x-link\r\n * @decorator component\r\n */\r\nexport const XLinkPrefix = 'x-link';\r\nconst X_LINK_CONFIG_NAME = 'link';\r\n\r\n/**\r\n * Link Property\r\n */\r\n@Component({ selector: `${XLinkPrefix}-property`, template: '' })\r\nexport class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 链接\r\n * @en_US Link\r\n * @example\r\n *\r\n * ```html\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_blank\">ng-nest</x-link>\r\n * ```\r\n *\r\n */\r\n readonly href = input<string>();\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n * @example\r\n *\r\n * ```html\r\n * <x-link icon=\"fto-chevron-left\">left</x-link>\r\n * <x-link icon=\"fto-chevron-right\">right</x-link>\r\n * ```\r\n *\r\n */\r\n readonly icon = input<string>();\r\n /**\r\n * @zh_CN 下划线\r\n * @en_US Underscore\r\n * @example\r\n *\r\n * ```html\r\n * <x-link underline>underline</x-link>\r\n * ```\r\n *\r\n */\r\n readonly underline = input<boolean, XBoolean>(this.config?.underline ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n * @example\r\n *\r\n * ```html\r\n * <x-link disabled>disabled</x-link>\r\n * ```\r\n *\r\n */\r\n readonly disabled = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 图标靠右对齐\r\n * @en_US Icons are aligned to the right\r\n * @example\r\n *\r\n * ```html\r\n * <x-link icon=\"fto-chevron-left\">left</x-link>\r\n * <x-link icon=\"fto-chevron-right\" iconRight>right</x-link>\r\n * ```\r\n *\r\n */\r\n readonly iconRight = input<boolean, XBoolean>(this.config?.iconRight ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 链接类型\r\n * @en_US Link type\r\n * @example\r\n *\r\n * ```html\r\n * <x-link type=\"primary\">primary</x-link>\r\n * <x-link type=\"success\">success</x-link>\r\n * <x-link type=\"warning\">warning</x-link>\r\n * <x-link type=\"danger\">danger</x-link>\r\n * <x-link type=\"info\">info</x-link>\r\n * ```\r\n *\r\n */\r\n readonly type = input<XLinkType>('initial');\r\n /**\r\n * @zh_CN 打开方式\r\n * @en_US Open method\r\n * @example\r\n *\r\n * ```html\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_self\">ng-nest</x-link>\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_blank\">ng-nest</x-link>\r\n * ```\r\n *\r\n */\r\n readonly target = input<string>();\r\n}\r\n\r\n/**\r\n * @zh_CN 链接类型\r\n * @en_US Link type\r\n */\r\nexport type XLinkType = XType;\r\n","import {\r\n Component,\r\n ViewEncapsulation,\r\n Renderer2,\r\n ElementRef,\r\n ChangeDetectionStrategy,\r\n inject,\r\n computed,\r\n viewChild,\r\n effect\r\n} from '@angular/core';\r\nimport { XLinkPrefix, XLinkProperty } from './link.property';\r\nimport { XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XIconComponent } from '@ng-nest/ui/icon';\r\nimport { NgClass } from '@angular/common';\r\n\r\n@Component({\r\n selector: `${XLinkPrefix}`,\r\n imports: [NgClass, XIconComponent],\r\n templateUrl: './link.component.html',\r\n styleUrls: ['./link.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XLinkComponent extends XLinkProperty {\r\n link = viewChild.required<ElementRef<HTMLLinkElement>>('link');\r\n\r\n classMap = computed(() => ({\r\n [`${XLinkPrefix}-${this.type()}`]: !XIsEmpty(this.type())\r\n }));\r\n\r\n private renderer = inject(Renderer2);\r\n\r\n constructor() {\r\n super();\r\n effect(() => {\r\n if (XIsEmpty(this.href()) && this.link()) {\r\n this.renderer.removeAttribute(this.link().nativeElement, 'href');\r\n }\r\n });\r\n }\r\n}\r\n","<a\r\n #link\r\n class=\"x-link\"\r\n [ngClass]=\"classMap()\"\r\n [class.x-link-disabled]=\"disabled()\"\r\n [class.x-link-underline]=\"underline() && !disabled()\"\r\n [class.x-link-icon-right]=\"iconRight()\"\r\n [class.x-link-only-icon]=\"icon() && !content.innerHTML.trim()\"\r\n [attr.href]=\"href()\"\r\n [attr.target]=\"target()\"\r\n>\r\n @if (icon()) {\r\n <x-icon [type]=\"icon()\"></x-icon>\r\n }\r\n <span #content><ng-content></ng-content></span>\r\n</a>\r\n","import { NgModule } from '@angular/core';\r\nimport { XLinkComponent } from './link.component';\r\n\r\n@NgModule({\r\n exports: [XLinkComponent],\r\n imports: [XLinkComponent]\r\n})\r\nexport class XLinkModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAIA;;;;AAIG;AACI,MAAM,WAAW,GAAG;AAC3B,MAAM,kBAAkB,GAAG,MAAM;AAEjC;;AAEG;MAEU,aAAc,SAAQ,iBAAiB,CAAC,kBAAkB,CAAC,CAAA;AADxE,IAAA,WAAA,GAAA;;AAEE;;;;;;;;;AASG;QACM,
|
|
1
|
+
{"version":3,"file":"ng-nest-ui-link.mjs","sources":["../../../../lib/ng-nest/ui/link/link.property.ts","../../../../lib/ng-nest/ui/link/link.component.ts","../../../../lib/ng-nest/ui/link/link.component.html","../../../../lib/ng-nest/ui/link/link.module.ts","../../../../lib/ng-nest/ui/link/ng-nest-ui-link.ts"],"sourcesContent":["import { XPropertyFunction, XToBoolean } from '@ng-nest/ui/core';\r\nimport { Component, input } from '@angular/core';\r\nimport type { XBoolean, XType } from '@ng-nest/ui/core';\r\n\r\n/**\r\n * Link\r\n * @selector x-link\r\n * @decorator component\r\n */\r\nexport const XLinkPrefix = 'x-link';\r\nconst X_LINK_CONFIG_NAME = 'link';\r\n\r\n/**\r\n * Link Property\r\n */\r\n@Component({ selector: `${XLinkPrefix}-property`, template: '' })\r\nexport class XLinkProperty extends XPropertyFunction(X_LINK_CONFIG_NAME) {\r\n /**\r\n * @zh_CN 链接\r\n * @en_US Link\r\n * @example\r\n *\r\n * ```html\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_blank\">ng-nest</x-link>\r\n * ```\r\n *\r\n */\r\n readonly href = input<string>();\r\n /**\r\n * @zh_CN 图标\r\n * @en_US Icon\r\n * @example\r\n *\r\n * ```html\r\n * <x-link icon=\"fto-chevron-left\">left</x-link>\r\n * <x-link icon=\"fto-chevron-right\">right</x-link>\r\n * ```\r\n *\r\n */\r\n readonly icon = input<string>();\r\n /**\r\n * @zh_CN 下划线\r\n * @en_US Underscore\r\n * @example\r\n *\r\n * ```html\r\n * <x-link underline>underline</x-link>\r\n * ```\r\n *\r\n */\r\n readonly underline = input<boolean, XBoolean>(this.config?.underline ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 禁用\r\n * @en_US Disabled\r\n * @example\r\n *\r\n * ```html\r\n * <x-link disabled>disabled</x-link>\r\n * ```\r\n *\r\n */\r\n readonly disabled = input<boolean, XBoolean>(false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 图标靠右对齐\r\n * @en_US Icons are aligned to the right\r\n * @example\r\n *\r\n * ```html\r\n * <x-link icon=\"fto-chevron-left\">left</x-link>\r\n * <x-link icon=\"fto-chevron-right\" iconRight>right</x-link>\r\n * ```\r\n *\r\n */\r\n readonly iconRight = input<boolean, XBoolean>(this.config?.iconRight ?? false, { transform: XToBoolean });\r\n /**\r\n * @zh_CN 链接类型\r\n * @en_US Link type\r\n * @example\r\n *\r\n * ```html\r\n * <x-link type=\"primary\">primary</x-link>\r\n * <x-link type=\"success\">success</x-link>\r\n * <x-link type=\"warning\">warning</x-link>\r\n * <x-link type=\"danger\">danger</x-link>\r\n * <x-link type=\"info\">info</x-link>\r\n * ```\r\n *\r\n */\r\n readonly type = input<XLinkType>('initial');\r\n /**\r\n * @zh_CN 打开方式\r\n * @en_US Open method\r\n * @example\r\n *\r\n * ```html\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_self\">ng-nest</x-link>\r\n * <x-link href=\"https://www.ngnest.com\" target=\"_blank\">ng-nest</x-link>\r\n * ```\r\n *\r\n */\r\n readonly target = input<string>();\r\n}\r\n\r\n/**\r\n * @zh_CN 链接类型\r\n * @en_US Link type\r\n */\r\nexport type XLinkType = XType;\r\n","import {\r\n Component,\r\n ViewEncapsulation,\r\n Renderer2,\r\n ElementRef,\r\n ChangeDetectionStrategy,\r\n inject,\r\n computed,\r\n viewChild,\r\n effect\r\n} from '@angular/core';\r\nimport { XLinkPrefix, XLinkProperty } from './link.property';\r\nimport { XIsEmpty } from '@ng-nest/ui/core';\r\nimport { XIconComponent } from '@ng-nest/ui/icon';\r\nimport { NgClass } from '@angular/common';\r\n\r\n@Component({\r\n selector: `${XLinkPrefix}`,\r\n imports: [NgClass, XIconComponent],\r\n templateUrl: './link.component.html',\r\n styleUrls: ['./link.component.scss'],\r\n encapsulation: ViewEncapsulation.None,\r\n changeDetection: ChangeDetectionStrategy.OnPush\r\n})\r\nexport class XLinkComponent extends XLinkProperty {\r\n link = viewChild.required<ElementRef<HTMLLinkElement>>('link');\r\n\r\n classMap = computed(() => ({\r\n [`${XLinkPrefix}-${this.type()}`]: !XIsEmpty(this.type())\r\n }));\r\n\r\n private renderer = inject(Renderer2);\r\n\r\n constructor() {\r\n super();\r\n effect(() => {\r\n if (XIsEmpty(this.href()) && this.link()) {\r\n this.renderer.removeAttribute(this.link().nativeElement, 'href');\r\n }\r\n });\r\n }\r\n}\r\n","<a\r\n #link\r\n class=\"x-link\"\r\n [ngClass]=\"classMap()\"\r\n [class.x-link-disabled]=\"disabled()\"\r\n [class.x-link-underline]=\"underline() && !disabled()\"\r\n [class.x-link-icon-right]=\"iconRight()\"\r\n [class.x-link-only-icon]=\"icon() && !content.innerHTML.trim()\"\r\n [attr.href]=\"href()\"\r\n [attr.target]=\"target()\"\r\n>\r\n @if (icon()) {\r\n <x-icon [type]=\"icon()\"></x-icon>\r\n }\r\n <span #content><ng-content></ng-content></span>\r\n</a>\r\n","import { NgModule } from '@angular/core';\r\nimport { XLinkComponent } from './link.component';\r\n\r\n@NgModule({\r\n exports: [XLinkComponent],\r\n imports: [XLinkComponent]\r\n})\r\nexport class XLinkModule {}\r\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;AAIA;;;;AAIG;AACI,MAAM,WAAW,GAAG;AAC3B,MAAM,kBAAkB,GAAG,MAAM;AAEjC;;AAEG;MAEU,aAAc,SAAQ,iBAAiB,CAAC,kBAAkB,CAAC,CAAA;AADxE,IAAA,WAAA,GAAA;;AAEE;;;;;;;;;AASG;QACM,IAAA,CAAA,IAAI,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;AAC/B;;;;;;;;;;AAUG;QACM,IAAA,CAAA,IAAI,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,MAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAU;AAC/B;;;;;;;;;AASG;QACM,IAAA,CAAA,SAAS,GAAG,KAAK,CAAoB,IAAI,CAAC,MAAM,EAAE,SAAS,IAAI,KAAK,6CAAI,SAAS,EAAE,UAAU,EAAA,CAAA,GAAA,CAAvB,EAAE,SAAS,EAAE,UAAU,EAAE,CAAA,CAAA,CAAC;AACzG;;;;;;;;;AASG;AACM,QAAA,IAAA,CAAA,QAAQ,GAAG,KAAK,CAAoB,KAAK,4CAAI,SAAS,EAAE,UAAU,EAAA,CAAA,GAAA,CAAvB,EAAE,SAAS,EAAE,UAAU,EAAE,GAAC;AAC9E;;;;;;;;;;AAUG;QACM,IAAA,CAAA,S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