@simplysm/angular 14.0.7 → 14.0.8
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/dist/core/utils/injectParent.d.ts +7 -0
- package/dist/core/utils/injectParent.d.ts.map +1 -0
- package/dist/core/utils/injectParent.js +26 -0
- package/dist/features/base/sd-base-container.control.d.ts +26 -0
- package/dist/features/base/sd-base-container.control.d.ts.map +1 -0
- package/dist/features/base/sd-base-container.control.js +183 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +3 -0
- package/dist/ui/data/list/sd-list-item.control.js +1 -1
- package/dist/ui/data/sheet/sd-sheet.control.d.ts +2 -1
- package/dist/ui/data/sheet/sd-sheet.control.d.ts.map +1 -1
- package/dist/ui/data/sheet/sd-sheet.control.js +16 -13
- package/dist/ui/data/sheet/useSheetCellAgent.d.ts.map +1 -1
- package/dist/ui/data/sheet/useSheetCellAgent.js +1 -2
- package/dist/ui/data/sheet/useSheetLayoutEngine.d.ts.map +1 -1
- package/dist/ui/data/sheet/useSheetLayoutEngine.js +1 -0
- package/dist/ui/layout/dock/sd-dock.control.d.ts +2 -0
- package/dist/ui/layout/dock/sd-dock.control.d.ts.map +1 -1
- package/dist/ui/layout/dock/sd-dock.control.js +13 -4
- package/dist/ui/layout/kanban/sd-kanban-lane.control.d.ts.map +1 -1
- package/dist/ui/layout/kanban/sd-kanban-lane.control.js +7 -1
- package/dist/ui/layout/sd-gap.control.d.ts +2 -2
- package/dist/ui/navigation/pagination/sd-pagination.control.d.ts.map +1 -1
- package/dist/ui/navigation/pagination/sd-pagination.control.js +7 -3
- package/dist/ui/navigation/sidebar/sd-sidebar-container.control.js +1 -1
- package/dist/ui/overlay/dropdown/sd-dropdown-popup.control.js +1 -1
- package/dist/ui/overlay/modal/sd-modal.control.d.ts +1 -0
- package/dist/ui/overlay/modal/sd-modal.control.d.ts.map +1 -1
- package/dist/ui/overlay/modal/sd-modal.control.js +10 -2
- package/dist/ui/overlay/toast/sd-toast.provider.d.ts.map +1 -1
- package/dist/ui/overlay/toast/sd-toast.provider.js +7 -3
- package/dist/ui/visual/sd-progress.control.d.ts +1 -0
- package/dist/ui/visual/sd-progress.control.d.ts.map +1 -1
- package/dist/ui/visual/sd-progress.control.js +5 -4
- package/package.json +5 -5
- package/src/core/utils/injectParent.ts +41 -0
- package/src/features/base/sd-base-container.control.ts +113 -0
- package/src/index.ts +4 -0
- package/src/ui/data/list/sd-list-item.control.ts +1 -1
- package/src/ui/data/sheet/sd-sheet.control.ts +17 -13
- package/src/ui/data/sheet/useSheetCellAgent.ts +1 -2
- package/src/ui/data/sheet/useSheetLayoutEngine.ts +1 -0
- package/src/ui/layout/dock/sd-dock.control.ts +15 -2
- package/src/ui/layout/kanban/sd-kanban-lane.control.ts +6 -3
- package/src/ui/navigation/pagination/sd-pagination.control.ts +5 -3
- package/src/ui/navigation/sidebar/sd-sidebar-container.control.ts +1 -1
- package/src/ui/overlay/dropdown/sd-dropdown-popup.control.ts +1 -1
- package/src/ui/overlay/modal/sd-modal.control.ts +9 -0
- package/src/ui/overlay/toast/sd-toast.provider.ts +9 -3
- package/src/ui/visual/sd-progress.control.ts +4 -1
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { type AbstractType } from "@angular/core";
|
|
2
|
+
export declare function injectParent<T = object>(): T;
|
|
3
|
+
export declare function injectParent<T = object>(type: AbstractType<T>): T;
|
|
4
|
+
export declare function injectParent<T = object>(type: AbstractType<T>, options: {
|
|
5
|
+
optional: true;
|
|
6
|
+
}): T | undefined;
|
|
7
|
+
//# sourceMappingURL=injectParent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"injectParent.d.ts","sourceRoot":"","sources":["..\\..\\..\\src\\core\\utils\\injectParent.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,YAAY,EAAsC,MAAM,eAAe,CAAC;AAEtF,wBAAgB,YAAY,CAAC,CAAC,GAAG,MAAM,KAAK,CAAC,CAAC;AAC9C,wBAAgB,YAAY,CAAC,CAAC,GAAG,MAAM,EAAE,IAAI,EAAE,YAAY,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC;AACnE,wBAAgB,YAAY,CAAC,CAAC,GAAG,MAAM,EACrC,IAAI,EAAE,YAAY,CAAC,CAAC,CAAC,EACrB,OAAO,EAAE;IAAE,QAAQ,EAAE,IAAI,CAAA;CAAE,GAC1B,CAAC,GAAG,SAAS,CAAC"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { inject, Injector, ViewContainerRef } from "@angular/core";
|
|
2
|
+
export function injectParent(type, options) {
|
|
3
|
+
let currentInjector = inject(ViewContainerRef).injector;
|
|
4
|
+
while (currentInjector != null) {
|
|
5
|
+
// Angular internal: NodeInjector._lView[CONTEXT=8]에 컴포넌트 인스턴스 저장
|
|
6
|
+
const lView = currentInjector._lView;
|
|
7
|
+
if (lView == null) {
|
|
8
|
+
break;
|
|
9
|
+
}
|
|
10
|
+
const comp = lView[8];
|
|
11
|
+
if (type == null) {
|
|
12
|
+
return comp;
|
|
13
|
+
}
|
|
14
|
+
if (comp instanceof type) {
|
|
15
|
+
return comp;
|
|
16
|
+
}
|
|
17
|
+
currentInjector = currentInjector.get(Injector, undefined, {
|
|
18
|
+
skipSelf: true,
|
|
19
|
+
optional: true,
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
if (options?.optional) {
|
|
23
|
+
return undefined;
|
|
24
|
+
}
|
|
25
|
+
throw new Error("부모 컴포넌트를 찾을 수 없습니다.");
|
|
26
|
+
}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { TemplateRef } from "@angular/core";
|
|
2
|
+
import { type TSdViewType } from "../../core/utils/useViewTypeSignal";
|
|
3
|
+
import * as i0 from "@angular/core";
|
|
4
|
+
export declare class SdBaseContainerControl {
|
|
5
|
+
private readonly _sdActivatedModal;
|
|
6
|
+
private readonly _sdAppStructure;
|
|
7
|
+
private readonly _parent;
|
|
8
|
+
private readonly _fullPageCode;
|
|
9
|
+
private readonly _currPageCode;
|
|
10
|
+
contentTplRef: import("@angular/core").Signal<TemplateRef<any>>;
|
|
11
|
+
pageTopbarTplRef: import("@angular/core").Signal<TemplateRef<any> | undefined>;
|
|
12
|
+
modalBottomTplRef: import("@angular/core").Signal<TemplateRef<any> | undefined>;
|
|
13
|
+
private readonly _parentViewType;
|
|
14
|
+
viewType: import("@angular/core").InputSignal<TSdViewType | undefined>;
|
|
15
|
+
currViewType: import("@angular/core").Signal<TSdViewType>;
|
|
16
|
+
header: import("@angular/core").InputSignal<string | undefined>;
|
|
17
|
+
modalOrPageTitle: import("@angular/core").Signal<any>;
|
|
18
|
+
initialized: import("@angular/core").InputSignal<boolean | undefined>;
|
|
19
|
+
restricted: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
20
|
+
busy: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
21
|
+
busyMessage: import("@angular/core").InputSignal<string | undefined>;
|
|
22
|
+
protected readonly tablerAlertTriangle = "<svg xmlns=\"http://www.w3.org/2000/svg\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-linecap=\"round\" stroke-linejoin=\"round\" style=\"stroke-width:var(--ng-icon__stroke-width, 2)\"><path stroke=\"none\" d=\"M0 0h24v24H0z\" fill=\"none\"></path><path d=\"M12 9v4\"></path><path d=\"M10.363 3.591l-8.106 13.534a1.914 1.914 0 0 0 1.636 2.871h16.214a1.914 1.914 0 0 0 1.636 -2.87l-8.106 -13.536a1.914 1.914 0 0 0 -3.274 0z\"></path><path d=\"M12 16h.01\"></path></svg>";
|
|
23
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<SdBaseContainerControl, never>;
|
|
24
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<SdBaseContainerControl, "sd-base-container", never, { "viewType": { "alias": "viewType"; "required": false; "isSignal": true; }; "header": { "alias": "header"; "required": false; "isSignal": true; }; "initialized": { "alias": "initialized"; "required": false; "isSignal": true; }; "restricted": { "alias": "restricted"; "required": false; "isSignal": true; }; "busy": { "alias": "busy"; "required": false; "isSignal": true; }; "busyMessage": { "alias": "busyMessage"; "required": false; "isSignal": true; }; }, {}, ["contentTplRef", "pageTopbarTplRef", "modalBottomTplRef"], never, true, never>;
|
|
25
|
+
}
|
|
26
|
+
//# sourceMappingURL=sd-base-container.control.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"sd-base-container.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\src\\features\\base\\sd-base-container.control.ts"],"names":[],"mappings":"AACA,OAAO,EAQL,WAAW,EAEZ,MAAM,eAAe,CAAC;AAQvB,OAAO,EAEL,KAAK,WAAW,EACjB,MAAM,oCAAoC,CAAC;;AAK5C,qBAqDa,sBAAsB;IACjC,OAAO,CAAC,QAAQ,CAAC,iBAAiB,CAAwD;IAC1F,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAkC;IAElE,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAkB;IAE1C,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA2B;IACzD,OAAO,CAAC,QAAQ,CAAC,aAAa,CAA8B;IAE5D,aAAa,mDAA8D;IAE3E,gBAAgB,+DAAwD;IACxE,iBAAiB,+DAAyD;IAE1E,OAAO,CAAC,QAAQ,CAAC,eAAe,CAAyC;IACzE,QAAQ,+DAAwB;IAChC,YAAY,8CAA6D;IAEzE,MAAM,0DAAmB;IACzB,gBAAgB,sCAKd;IAEF,WAAW,2DAAyC;IACpD,UAAU,qEAAiD;IAC3D,IAAI,qEAAiD;IACrD,WAAW,0DAAmB;IAE9B,SAAS,CAAC,QAAQ,CAAC,mBAAmB,ifAAuB;yCA/BlD,sBAAsB;2CAAtB,sBAAsB;CAgClC"}
|
|
@@ -0,0 +1,183 @@
|
|
|
1
|
+
import { NgTemplateOutlet } from "@angular/common";
|
|
2
|
+
import { booleanAttribute, ChangeDetectionStrategy, Component, computed, contentChild, inject, input, TemplateRef, ViewEncapsulation, } from "@angular/core";
|
|
3
|
+
import { SdBusyContainerControl } from "../../ui/overlay/busy/sd-busy-container.control";
|
|
4
|
+
import { SdTopbarContainerControl } from "../../ui/navigation/topbar/sd-topbar-container.control";
|
|
5
|
+
import { SdTopbarControl } from "../../ui/navigation/topbar/sd-topbar.control";
|
|
6
|
+
import { SdAppStructureProvider } from "../../core/providers/sd-app-structure.provider";
|
|
7
|
+
import { SdActivatedModalProvider } from "../../ui/overlay/modal/sd-modal.provider";
|
|
8
|
+
import { useCurrentPageCodeSignal } from "../../core/utils/useCurrentPageCodeSignal";
|
|
9
|
+
import { useFullPageCodeSignal } from "../../core/utils/useFullPageCodeSignal";
|
|
10
|
+
import { useViewTypeSignal, } from "../../core/utils/useViewTypeSignal";
|
|
11
|
+
import { injectParent } from "../../core/utils/injectParent";
|
|
12
|
+
import { NgIcon } from "@ng-icons/core";
|
|
13
|
+
import { tablerAlertTriangle } from "@ng-icons/tabler-icons";
|
|
14
|
+
import * as i0 from "@angular/core";
|
|
15
|
+
const _c0 = ["contentTpl"];
|
|
16
|
+
const _c1 = ["pageTopbarTpl"];
|
|
17
|
+
const _c2 = ["modalBottomTpl"];
|
|
18
|
+
function SdBaseContainerControl_Conditional_1_Conditional_0_Template(rf, ctx) { if (rf & 1) {
|
|
19
|
+
i0.ɵɵelementStart(0, "div", 1);
|
|
20
|
+
i0.ɵɵelement(1, "br")(2, "ng-icon", 4)(3, "br")(4, "br");
|
|
21
|
+
i0.ɵɵtext(5);
|
|
22
|
+
i0.ɵɵelementEnd();
|
|
23
|
+
} if (rf & 2) {
|
|
24
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
25
|
+
i0.ɵɵadvance(2);
|
|
26
|
+
i0.ɵɵproperty("svg", ctx_r0.tablerAlertTriangle)("size", "5em");
|
|
27
|
+
i0.ɵɵadvance(3);
|
|
28
|
+
i0.ɵɵtextInterpolate1(" '", ctx_r0.modalOrPageTitle(), "'\uC5D0 \uB300\uD55C \uC0AC\uC6A9\uAD8C\uD55C\uC774 \uC5C6\uC2B5\uB2C8\uB2E4. \uC2DC\uC2A4\uD15C \uAD00\uB9AC\uC790\uC5D0\uAC8C \uBB38\uC758\uD558\uC138\uC694. ");
|
|
29
|
+
} }
|
|
30
|
+
function SdBaseContainerControl_Conditional_1_Conditional_1_ng_template_4_Template(rf, ctx) { }
|
|
31
|
+
function SdBaseContainerControl_Conditional_1_Conditional_1_ng_template_6_Template(rf, ctx) { }
|
|
32
|
+
function SdBaseContainerControl_Conditional_1_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
33
|
+
i0.ɵɵelementStart(0, "sd-topbar-container")(1, "sd-topbar")(2, "h4");
|
|
34
|
+
i0.ɵɵtext(3);
|
|
35
|
+
i0.ɵɵelementEnd();
|
|
36
|
+
i0.ɵɵtemplate(4, SdBaseContainerControl_Conditional_1_Conditional_1_ng_template_4_Template, 0, 0, "ng-template", 3);
|
|
37
|
+
i0.ɵɵelementEnd();
|
|
38
|
+
i0.ɵɵelementStart(5, "div", 5);
|
|
39
|
+
i0.ɵɵtemplate(6, SdBaseContainerControl_Conditional_1_Conditional_1_ng_template_6_Template, 0, 0, "ng-template", 3);
|
|
40
|
+
i0.ɵɵelementEnd()();
|
|
41
|
+
} if (rf & 2) {
|
|
42
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
43
|
+
i0.ɵɵadvance(3);
|
|
44
|
+
i0.ɵɵtextInterpolate(ctx_r0.modalOrPageTitle());
|
|
45
|
+
i0.ɵɵadvance();
|
|
46
|
+
i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.pageTopbarTplRef() ?? null);
|
|
47
|
+
i0.ɵɵadvance(2);
|
|
48
|
+
i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.contentTplRef());
|
|
49
|
+
} }
|
|
50
|
+
function SdBaseContainerControl_Conditional_1_Conditional_2_ng_template_2_Template(rf, ctx) { }
|
|
51
|
+
function SdBaseContainerControl_Conditional_1_Conditional_2_Conditional_3_ng_template_1_Template(rf, ctx) { }
|
|
52
|
+
function SdBaseContainerControl_Conditional_1_Conditional_2_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
53
|
+
i0.ɵɵelementStart(0, "div", 7);
|
|
54
|
+
i0.ɵɵtemplate(1, SdBaseContainerControl_Conditional_1_Conditional_2_Conditional_3_ng_template_1_Template, 0, 0, "ng-template", 3);
|
|
55
|
+
i0.ɵɵelementEnd();
|
|
56
|
+
} if (rf & 2) {
|
|
57
|
+
const ctx_r0 = i0.ɵɵnextContext(3);
|
|
58
|
+
i0.ɵɵadvance();
|
|
59
|
+
i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.modalBottomTplRef() ?? null);
|
|
60
|
+
} }
|
|
61
|
+
function SdBaseContainerControl_Conditional_1_Conditional_2_Template(rf, ctx) { if (rf & 1) {
|
|
62
|
+
i0.ɵɵelementStart(0, "div", 2)(1, "div", 6);
|
|
63
|
+
i0.ɵɵtemplate(2, SdBaseContainerControl_Conditional_1_Conditional_2_ng_template_2_Template, 0, 0, "ng-template", 3);
|
|
64
|
+
i0.ɵɵelementEnd();
|
|
65
|
+
i0.ɵɵconditionalCreate(3, SdBaseContainerControl_Conditional_1_Conditional_2_Conditional_3_Template, 2, 1, "div", 7);
|
|
66
|
+
i0.ɵɵelementEnd();
|
|
67
|
+
} if (rf & 2) {
|
|
68
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
69
|
+
i0.ɵɵadvance(2);
|
|
70
|
+
i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.contentTplRef());
|
|
71
|
+
i0.ɵɵadvance();
|
|
72
|
+
i0.ɵɵconditional(ctx_r0.modalBottomTplRef() ? 3 : -1);
|
|
73
|
+
} }
|
|
74
|
+
function SdBaseContainerControl_Conditional_1_Conditional_3_ng_template_0_Template(rf, ctx) { }
|
|
75
|
+
function SdBaseContainerControl_Conditional_1_Conditional_3_Template(rf, ctx) { if (rf & 1) {
|
|
76
|
+
i0.ɵɵtemplate(0, SdBaseContainerControl_Conditional_1_Conditional_3_ng_template_0_Template, 0, 0, "ng-template", 3);
|
|
77
|
+
} if (rf & 2) {
|
|
78
|
+
const ctx_r0 = i0.ɵɵnextContext(2);
|
|
79
|
+
i0.ɵɵproperty("ngTemplateOutlet", ctx_r0.contentTplRef());
|
|
80
|
+
} }
|
|
81
|
+
function SdBaseContainerControl_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
82
|
+
i0.ɵɵconditionalCreate(0, SdBaseContainerControl_Conditional_1_Conditional_0_Template, 6, 3, "div", 1)(1, SdBaseContainerControl_Conditional_1_Conditional_1_Template, 7, 3, "sd-topbar-container")(2, SdBaseContainerControl_Conditional_1_Conditional_2_Template, 4, 2, "div", 2)(3, SdBaseContainerControl_Conditional_1_Conditional_3_Template, 1, 1, null, 3);
|
|
83
|
+
} if (rf & 2) {
|
|
84
|
+
const ctx_r0 = i0.ɵɵnextContext();
|
|
85
|
+
i0.ɵɵconditional(ctx_r0.restricted() ? 0 : ctx_r0.currViewType() === "page" ? 1 : ctx_r0.currViewType() === "modal" ? 2 : 3);
|
|
86
|
+
} }
|
|
87
|
+
export class SdBaseContainerControl {
|
|
88
|
+
_sdActivatedModal = inject(SdActivatedModalProvider, { optional: true });
|
|
89
|
+
_sdAppStructure = inject(SdAppStructureProvider);
|
|
90
|
+
_parent = injectParent();
|
|
91
|
+
_fullPageCode = useFullPageCodeSignal();
|
|
92
|
+
_currPageCode = useCurrentPageCodeSignal();
|
|
93
|
+
contentTplRef = contentChild.required("contentTpl", { read: TemplateRef });
|
|
94
|
+
pageTopbarTplRef = contentChild("pageTopbarTpl", { ...(ngDevMode ? { debugName: "pageTopbarTplRef" } : /* istanbul ignore next */ {}), read: TemplateRef });
|
|
95
|
+
modalBottomTplRef = contentChild("modalBottomTpl", { ...(ngDevMode ? { debugName: "modalBottomTplRef" } : /* istanbul ignore next */ {}), read: TemplateRef });
|
|
96
|
+
_parentViewType = useViewTypeSignal(() => this._parent);
|
|
97
|
+
viewType = input(...(ngDevMode ? [undefined, { debugName: "viewType" }] : /* istanbul ignore next */ []));
|
|
98
|
+
currViewType = computed(() => this.viewType() ?? this._parentViewType(), ...(ngDevMode ? [{ debugName: "currViewType" }] : /* istanbul ignore next */ []));
|
|
99
|
+
header = input(...(ngDevMode ? [undefined, { debugName: "header" }] : /* istanbul ignore next */ []));
|
|
100
|
+
modalOrPageTitle = computed(() => this.header() ??
|
|
101
|
+
this._sdActivatedModal?.modalComponent()?.title() ??
|
|
102
|
+
this._sdAppStructure.getTitleByFullCode(this._currPageCode?.() ?? this._fullPageCode()), ...(ngDevMode ? [{ debugName: "modalOrPageTitle" }] : /* istanbul ignore next */ []));
|
|
103
|
+
initialized = input(undefined, ...(ngDevMode ? [{ debugName: "initialized" }] : /* istanbul ignore next */ []));
|
|
104
|
+
restricted = input(false, { ...(ngDevMode ? { debugName: "restricted" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
105
|
+
busy = input(false, { ...(ngDevMode ? { debugName: "busy" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
106
|
+
busyMessage = input(...(ngDevMode ? [undefined, { debugName: "busyMessage" }] : /* istanbul ignore next */ []));
|
|
107
|
+
tablerAlertTriangle = tablerAlertTriangle;
|
|
108
|
+
static ɵfac = function SdBaseContainerControl_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SdBaseContainerControl)(); };
|
|
109
|
+
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SdBaseContainerControl, selectors: [["sd-base-container"]], contentQueries: function SdBaseContainerControl_ContentQueries(rf, ctx, dirIndex) { if (rf & 1) {
|
|
110
|
+
i0.ɵɵcontentQuerySignal(dirIndex, ctx.contentTplRef, _c0, 5, TemplateRef)(dirIndex, ctx.pageTopbarTplRef, _c1, 5, TemplateRef)(dirIndex, ctx.modalBottomTplRef, _c2, 5, TemplateRef);
|
|
111
|
+
} if (rf & 2) {
|
|
112
|
+
i0.ɵɵqueryAdvance(3);
|
|
113
|
+
} }, inputs: { viewType: [1, "viewType"], header: [1, "header"], initialized: [1, "initialized"], restricted: [1, "restricted"], busy: [1, "busy"], busyMessage: [1, "busyMessage"] }, decls: 2, vars: 3, consts: [[3, "busy", "message"], [1, "fill", "tx-theme-gray-light", "p-xxl", "tx-center"], [1, "flex-column", "fill"], [3, "ngTemplateOutlet"], [3, "svg", "size"], [1, "fill"], [1, "flex-fill"], [1, "bdt", "bdt-theme-gray-lightest"]], template: function SdBaseContainerControl_Template(rf, ctx) { if (rf & 1) {
|
|
114
|
+
i0.ɵɵelementStart(0, "sd-busy-container", 0);
|
|
115
|
+
i0.ɵɵconditionalCreate(1, SdBaseContainerControl_Conditional_1_Template, 4, 1);
|
|
116
|
+
i0.ɵɵelementEnd();
|
|
117
|
+
} if (rf & 2) {
|
|
118
|
+
i0.ɵɵproperty("busy", ctx.busy())("message", ctx.busyMessage());
|
|
119
|
+
i0.ɵɵadvance();
|
|
120
|
+
i0.ɵɵconditional(ctx.initialized() === undefined || ctx.initialized() ? 1 : -1);
|
|
121
|
+
} }, dependencies: [SdBusyContainerControl,
|
|
122
|
+
SdTopbarContainerControl,
|
|
123
|
+
SdTopbarControl,
|
|
124
|
+
NgTemplateOutlet,
|
|
125
|
+
NgIcon], encapsulation: 2, changeDetection: 0 });
|
|
126
|
+
}
|
|
127
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassMetadata(SdBaseContainerControl, [{
|
|
128
|
+
type: Component,
|
|
129
|
+
args: [{
|
|
130
|
+
selector: "sd-base-container",
|
|
131
|
+
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
132
|
+
encapsulation: ViewEncapsulation.None,
|
|
133
|
+
standalone: true,
|
|
134
|
+
imports: [
|
|
135
|
+
SdBusyContainerControl,
|
|
136
|
+
SdTopbarContainerControl,
|
|
137
|
+
SdTopbarControl,
|
|
138
|
+
NgTemplateOutlet,
|
|
139
|
+
NgIcon,
|
|
140
|
+
],
|
|
141
|
+
template: `
|
|
142
|
+
<sd-busy-container [busy]="busy()" [message]="busyMessage()">
|
|
143
|
+
@if (initialized() === undefined || initialized()) {
|
|
144
|
+
@if (restricted()) {
|
|
145
|
+
<div class="fill tx-theme-gray-light p-xxl tx-center">
|
|
146
|
+
<br />
|
|
147
|
+
<ng-icon [svg]="tablerAlertTriangle" [size]="'5em'" />
|
|
148
|
+
<br />
|
|
149
|
+
<br />
|
|
150
|
+
'{{ modalOrPageTitle() }}'에 대한 사용권한이 없습니다. 시스템 관리자에게 문의하세요.
|
|
151
|
+
</div>
|
|
152
|
+
} @else if (currViewType() === "page") {
|
|
153
|
+
<sd-topbar-container>
|
|
154
|
+
<sd-topbar>
|
|
155
|
+
<h4>{{ modalOrPageTitle() }}</h4>
|
|
156
|
+
|
|
157
|
+
<ng-template [ngTemplateOutlet]="pageTopbarTplRef() ?? null" />
|
|
158
|
+
</sd-topbar>
|
|
159
|
+
|
|
160
|
+
<div class="fill">
|
|
161
|
+
<ng-template [ngTemplateOutlet]="contentTplRef()" />
|
|
162
|
+
</div>
|
|
163
|
+
</sd-topbar-container>
|
|
164
|
+
} @else if (currViewType() === "modal") {
|
|
165
|
+
<div class="flex-column fill">
|
|
166
|
+
<div class="flex-fill">
|
|
167
|
+
<ng-template [ngTemplateOutlet]="contentTplRef()" />
|
|
168
|
+
</div>
|
|
169
|
+
@if (modalBottomTplRef()) {
|
|
170
|
+
<div class="bdt bdt-theme-gray-lightest">
|
|
171
|
+
<ng-template [ngTemplateOutlet]="modalBottomTplRef() ?? null" />
|
|
172
|
+
</div>
|
|
173
|
+
}
|
|
174
|
+
</div>
|
|
175
|
+
} @else {
|
|
176
|
+
<ng-template [ngTemplateOutlet]="contentTplRef()" />
|
|
177
|
+
}
|
|
178
|
+
}
|
|
179
|
+
</sd-busy-container>
|
|
180
|
+
`,
|
|
181
|
+
}]
|
|
182
|
+
}], null, { contentTplRef: [{ type: i0.ContentChild, args: ["contentTpl", { ...{ read: TemplateRef }, isSignal: true }] }], pageTopbarTplRef: [{ type: i0.ContentChild, args: ["pageTopbarTpl", { ...{ read: TemplateRef }, isSignal: true }] }], modalBottomTplRef: [{ type: i0.ContentChild, args: ["modalBottomTpl", { ...{ read: TemplateRef }, isSignal: true }] }], viewType: [{ type: i0.Input, args: [{ isSignal: true, alias: "viewType", required: false }] }], header: [{ type: i0.Input, args: [{ isSignal: true, alias: "header", required: false }] }], initialized: [{ type: i0.Input, args: [{ isSignal: true, alias: "initialized", required: false }] }], restricted: [{ type: i0.Input, args: [{ isSignal: true, alias: "restricted", required: false }] }], busy: [{ type: i0.Input, args: [{ isSignal: true, alias: "busy", required: false }] }], busyMessage: [{ type: i0.Input, args: [{ isSignal: true, alias: "busyMessage", required: false }] }] }); })();
|
|
183
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SdBaseContainerControl, { className: "SdBaseContainerControl", filePath: "packages/angular/src/features/base/sd-base-container.control.ts", lineNumber: 81 }); })();
|
package/dist/index.d.ts
CHANGED
|
@@ -40,6 +40,8 @@ export { useViewTypeSignal, type TSdViewType } from "./core/utils/useViewTypeSig
|
|
|
40
40
|
export { setupCanDeactivate } from "./core/utils/setups/setupCanDeactivate";
|
|
41
41
|
export { useExpandingManager, type IExpandItemDef, } from "./core/utils/useExpandingManager";
|
|
42
42
|
export { useSelectionManager } from "./core/utils/useSelectionManager";
|
|
43
|
+
export { injectParent } from "./core/utils/injectParent";
|
|
44
|
+
export { SdBaseContainerControl } from "./features/base/sd-base-container.control";
|
|
43
45
|
export { SdDockContainerControl } from "./ui/layout/dock/sd-dock-container.control";
|
|
44
46
|
export { SdDockControl } from "./ui/layout/dock/sd-dock.control";
|
|
45
47
|
export { SdPaneDirective } from "./ui/layout/sd-pane.directive";
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["..\\src\\index.ts"],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qC,CAAC;AACrE,OAAO,EACL,eAAe,EACf,wBAAwB,EACxB,KAAK,QAAQ,EACb,KAAK,YAAY,EACjB,KAAK,eAAe,GACrB,MAAM,sCAAsC,CAAC;AAC9C,OAAO,EAAE,oBAAoB,EAAE,MAAM,4CAA4C,CAAC;AAClF,OAAO,EAAE,qBAAqB,EAAE,MAAM,6CAA6C,CAAC;AAGpF,OAAO,EAAE,cAAc,EAAE,MAAM,qCAAqC,CAAC;AACrE,OAAO,EAAE,uBAAuB,EAAE,MAAM,+CAA+C,CAAC;AACxF,OAAO,EACL,eAAe,EACf,KAAK,gBAAgB,EACrB,KAAK,aAAa,EAClB,KAAK,QAAQ,EACb,KAAK,aAAa,GACnB,MAAM,sCAAsC,CAAC;AAG9C,OAAO,EAAE,sBAAsB,EAAE,MAAM,6CAA6C,CAAC;AACrF,OAAO,EACL,cAAc,EACd,KAAK,WAAW,GACjB,MAAM,oCAAoC,CAAC;AAG5C,OAAO,EACL,eAAe,EACf,KAAK,QAAQ,EACb,KAAK,aAAa,GACnB,MAAM,oCAAoC,CAAC;AAG5C,OAAO,EAAE,iBAAiB,EAAE,KAAK,WAAW,EAAE,MAAM,gCAAgC,CAAC;AACrF,YAAY,EAAE,sBAAsB,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -40,6 +40,9 @@ export { useViewTypeSignal } from "./core/utils/useViewTypeSignal";
|
|
|
40
40
|
export { setupCanDeactivate } from "./core/utils/setups/setupCanDeactivate";
|
|
41
41
|
export { useExpandingManager, } from "./core/utils/useExpandingManager";
|
|
42
42
|
export { useSelectionManager } from "./core/utils/useSelectionManager";
|
|
43
|
+
export { injectParent } from "./core/utils/injectParent";
|
|
44
|
+
// features
|
|
45
|
+
export { SdBaseContainerControl } from "./features/base/sd-base-container.control";
|
|
43
46
|
// ui/layout
|
|
44
47
|
export { SdDockContainerControl } from "./ui/layout/dock/sd-dock-container.control";
|
|
45
48
|
export { SdDockControl } from "./ui/layout/dock/sd-dock.control";
|
|
@@ -53,7 +53,7 @@ export class SdListItemControl {
|
|
|
53
53
|
return this.layout() === "flat" ? true : this.open();
|
|
54
54
|
}, ...(ngDevMode ? [{ debugName: "childrenOpen" }] : /* istanbul ignore next */ []));
|
|
55
55
|
constructor() {
|
|
56
|
-
setupRipple(() => !this.readonly() &&
|
|
56
|
+
setupRipple(() => !this.readonly() && this.layout() !== "flat");
|
|
57
57
|
}
|
|
58
58
|
onContentClick() {
|
|
59
59
|
if (this.readonly())
|
|
@@ -59,7 +59,7 @@ export declare class SdSheetControl<T> {
|
|
|
59
59
|
constructor();
|
|
60
60
|
_isResizing: import("@angular/core").WritableSignal<boolean>;
|
|
61
61
|
_resizeIndicatorLeft: import("@angular/core").WritableSignal<number>;
|
|
62
|
-
private
|
|
62
|
+
private _lastResizeEndTimeStamp;
|
|
63
63
|
private _resizingCleanup;
|
|
64
64
|
private readonly _configResource;
|
|
65
65
|
layout: {
|
|
@@ -114,6 +114,7 @@ export declare class SdSheetControl<T> {
|
|
|
114
114
|
toggleAll(): void;
|
|
115
115
|
isSelected(item: T): boolean;
|
|
116
116
|
};
|
|
117
|
+
private readonly _columnControlMap;
|
|
117
118
|
getColumnCellTpl(key: string): import("@angular/core").TemplateRef<void> | null;
|
|
118
119
|
getColumnSummaryTpl(key: string): import("@angular/core").TemplateRef<void> | null;
|
|
119
120
|
getHeaderCellStyle(cell: ISdSheetHeaderDef): string | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sd-sheet.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\data\\sheet\\sd-sheet.control.ts"],"names":[],"mappings":"AAeA,OAAO,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAerE,OAAO,EAAqB,KAAK,WAAW,EAAE,MAAM,uCAAuC,CAAC;AAK5F,OAAO,KAAK,EACV,iBAAiB,EAEjB,iBAAiB,EACjB,6BAA6B,EAC9B,MAAM,SAAS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BAAiB,GAAG,MAAM,GAAG,IAAI;IAOxD,OAAO,CAAC,eAAe;IAkBvB,OAAO,CAAC,cAAc;IAatB,gBAAgB,CAAC,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,iBAAiB,EAAE,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG,MAAM,GAAG,IAAI;IAanF,gBAAgB,CAAC,KAAK,EAAE,aAAa,GAAG,OAAO,CAAC,IAAI,CAAC;IAI3D,UAAU,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI;IAInC,aAAa,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI;IAItC,aAAa,CAAC,KAAK,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,GAAG,IAAI;IAIlD,aAAa,CAAC,KAAK,EAAE,aAAa,EAAE,IAAI,EAAE,CAAC,EAAE,MAAM,EAAE,MAAM,GAAG,IAAI;IAI5D,mBAAmB,IAAI,OAAO,CAAC,IAAI,CAAC;IAkB1C,kBAAkB,CAAC,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,iBAAiB,GAAG,IAAI;IA4CtE,iBAAiB,CAAC,KAAK,EAAE,UAAU,EAAE,MAAM,EAAE,iBAAiB,GAAG,IAAI;IAarE,OAAO,CAAC,iBAAiB;yCArad,cAAc;2CAAd,cAAc;CA8a1B;AAGD,YAAY,EAAE,WAAW,EAAE,MAAM,uCAAuC,CAAC"}
|
|
@@ -319,7 +319,7 @@ export class SdSheetControl {
|
|
|
319
319
|
// Resizing state
|
|
320
320
|
_isResizing = signal(false, ...(ngDevMode ? [{ debugName: "_isResizing" }] : /* istanbul ignore next */ []));
|
|
321
321
|
_resizeIndicatorLeft = signal(0, ...(ngDevMode ? [{ debugName: "_resizeIndicatorLeft" }] : /* istanbul ignore next */ []));
|
|
322
|
-
|
|
322
|
+
_lastResizeEndTimeStamp = 0;
|
|
323
323
|
_resizingCleanup = null;
|
|
324
324
|
// Config resource
|
|
325
325
|
_configResource = useSdSystemConfigResource({
|
|
@@ -404,12 +404,19 @@ export class SdSheetControl {
|
|
|
404
404
|
selectMode: this.selectMode,
|
|
405
405
|
getItemSelectableFn: this.getItemSelectableFn,
|
|
406
406
|
});
|
|
407
|
+
_columnControlMap = computed(() => {
|
|
408
|
+
const map = new Map();
|
|
409
|
+
for (const col of this.columnControls()) {
|
|
410
|
+
map.set(col.key(), col);
|
|
411
|
+
}
|
|
412
|
+
return map;
|
|
413
|
+
}, ...(ngDevMode ? [{ debugName: "_columnControlMap" }] : /* istanbul ignore next */ []));
|
|
407
414
|
getColumnCellTpl(key) {
|
|
408
|
-
const col = this.
|
|
415
|
+
const col = this._columnControlMap().get(key);
|
|
409
416
|
return col?.cellTplRef() ?? null;
|
|
410
417
|
}
|
|
411
418
|
getColumnSummaryTpl(key) {
|
|
412
|
-
const col = this.
|
|
419
|
+
const col = this._columnControlMap().get(key);
|
|
413
420
|
return col?.summaryTplRef() ?? null;
|
|
414
421
|
}
|
|
415
422
|
getHeaderCellStyle(cell) {
|
|
@@ -436,9 +443,8 @@ export class SdSheetControl {
|
|
|
436
443
|
if (fixedStyle != null) {
|
|
437
444
|
parts.push(fixedStyle);
|
|
438
445
|
}
|
|
439
|
-
const
|
|
440
|
-
|
|
441
|
-
: undefined;
|
|
446
|
+
const styleFn = this.getItemCellStyleFn();
|
|
447
|
+
const customStyle = styleFn != null ? styleFn(item, colDef.key) : undefined;
|
|
442
448
|
if (customStyle != null) {
|
|
443
449
|
parts.push(customStyle);
|
|
444
450
|
}
|
|
@@ -473,7 +479,7 @@ export class SdSheetControl {
|
|
|
473
479
|
}
|
|
474
480
|
}
|
|
475
481
|
onHeaderClick(event, cell) {
|
|
476
|
-
if (this.
|
|
482
|
+
if (event.timeStamp - this._lastResizeEndTimeStamp < 50)
|
|
477
483
|
return;
|
|
478
484
|
if (cell.colDef == null)
|
|
479
485
|
return;
|
|
@@ -556,7 +562,8 @@ export class SdSheetControl {
|
|
|
556
562
|
}
|
|
557
563
|
getDataCellClass(item, colDef, r, c) {
|
|
558
564
|
const parts = [];
|
|
559
|
-
const
|
|
565
|
+
const classFn = this.getItemCellClassFn();
|
|
566
|
+
const customClass = classFn != null ? classFn(item, colDef.key) : undefined;
|
|
560
567
|
if (customClass != null) {
|
|
561
568
|
parts.push(customClass);
|
|
562
569
|
}
|
|
@@ -602,7 +609,6 @@ export class SdSheetControl {
|
|
|
602
609
|
const th = event.target.parentElement;
|
|
603
610
|
const startWidth = th.offsetWidth;
|
|
604
611
|
this._isResizing.set(true);
|
|
605
|
-
this._isOnResizing = true;
|
|
606
612
|
this._resizeIndicatorLeft.set(th.offsetLeft + th.offsetWidth - container.scrollLeft);
|
|
607
613
|
const onMouseMove = (e) => {
|
|
608
614
|
const deltaX = e.clientX - startX;
|
|
@@ -617,10 +623,7 @@ export class SdSheetControl {
|
|
|
617
623
|
const newWidth = Math.max(startWidth + deltaX, 5);
|
|
618
624
|
this._isResizing.set(false);
|
|
619
625
|
this._saveColumnConfig(colDef.key, { width: `${newWidth}px` });
|
|
620
|
-
|
|
621
|
-
setTimeout(() => {
|
|
622
|
-
this._isOnResizing = false;
|
|
623
|
-
}, 300);
|
|
626
|
+
this._lastResizeEndTimeStamp = e.timeStamp;
|
|
624
627
|
};
|
|
625
628
|
document.addEventListener("mousemove", onMouseMove);
|
|
626
629
|
document.addEventListener("mouseup", onMouseUp);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSheetCellAgent.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\data\\sheet\\useSheetCellAgent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAEjE,wBAAgB,iBAAiB,CAAC,OAAO,EAAE;IACzC,WAAW,EAAE,UAAU,CAAC,OAAO,mBAAmB,CAAC,CAAC;CACrD;;WACsC,MAAM;WAAK,MAAM;;2BAGxB;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE,KAAG,OAAO;sBAMvC,oBAAoB,KAAG;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE;kCAwD7B,aAAa,KAAG,OAAO,CAAC,IAAI,CAAC;
|
|
1
|
+
{"version":3,"file":"useSheetCellAgent.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\data\\sheet\\useSheetCellAgent.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,uBAAuB,CAAC;AAEjE,wBAAgB,iBAAiB,CAAC,OAAO,EAAE;IACzC,WAAW,EAAE,UAAU,CAAC,OAAO,mBAAmB,CAAC,CAAC;CACrD;;WACsC,MAAM;WAAK,MAAM;;2BAGxB;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE,KAAG,OAAO;sBAMvC,oBAAoB,KAAG;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE;kCAwD7B,aAAa,KAAG,OAAO,CAAC,IAAI,CAAC;mCA2JlC,UAAU,KAAG,IAAI;+BAQrB,UAAU,KAAG,IAAI;EA+BpD"}
|
|
@@ -175,8 +175,7 @@ export function useSheetCellAgent(options) {
|
|
|
175
175
|
return;
|
|
176
176
|
}
|
|
177
177
|
event.preventDefault();
|
|
178
|
-
|
|
179
|
-
await navigator.clipboard.writeText(text);
|
|
178
|
+
await navigator.clipboard.writeText(td.textContent);
|
|
180
179
|
return;
|
|
181
180
|
}
|
|
182
181
|
// Ctrl+V (paste)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useSheetLayoutEngine.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\data\\sheet\\useSheetLayoutEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,MAAM,EAAE,MAAM,eAAe,CAAC;AACtD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAC1E,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEpF,wBAAgB,oBAAoB,CAAC,OAAO,EAAE;IAC5C,cAAc,EAAE,MAAM,CAAC,SAAS,sBAAsB,EAAE,CAAC,CAAC;IAC1D,MAAM,EAAE,MAAM,CAAC,cAAc,GAAG,SAAS,CAAC,CAAC;CAC5C;;;;;;
|
|
1
|
+
{"version":3,"file":"useSheetLayoutEngine.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\data\\sheet\\useSheetLayoutEngine.ts"],"names":[],"mappings":"AAAA,OAAO,EAAY,KAAK,MAAM,EAAE,MAAM,eAAe,CAAC;AACtD,OAAO,KAAK,EAAE,sBAAsB,EAAE,MAAM,6BAA6B,CAAC;AAC1E,OAAO,KAAK,EAAE,iBAAiB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,SAAS,CAAC;AAEpF,wBAAgB,oBAAoB,CAAC,OAAO,EAAE;IAC5C,cAAc,EAAE,MAAM,CAAC,SAAS,sBAAsB,EAAE,CAAC,CAAC;IAC1D,MAAM,EAAE,MAAM,CAAC,cAAc,GAAG,SAAS,CAAC,CAAC;CAC5C;;;;;;EAwIA"}
|
|
@@ -2,6 +2,8 @@ import type { ISdResizeEvent } from "../../../core/plugins/events/sd-resize-even
|
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class SdDockControl {
|
|
4
4
|
private readonly _elRef;
|
|
5
|
+
private readonly _destroyRef;
|
|
6
|
+
private _dragCleanup;
|
|
5
7
|
key: import("@angular/core").InputSignal<string | undefined>;
|
|
6
8
|
position: import("@angular/core").InputSignal<"bottom" | "left" | "right" | "top">;
|
|
7
9
|
resizable: import("@angular/core").InputSignalWithTransform<boolean, unknown>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sd-dock.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\layout\\dock\\sd-dock.control.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"sd-dock.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\layout\\dock\\sd-dock.control.ts"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,qDAAqD,CAAC;;AAE1F,qBAyEa,aAAa;IACxB,OAAO,CAAC,QAAQ,CAAC,MAAM,CAAmC;IAC1D,OAAO,CAAC,QAAQ,CAAC,WAAW,CAAsB;IAElD,OAAO,CAAC,YAAY,CAA2B;IAE/C,GAAG,0DAAmB;IACtB,QAAQ,2EAAqD;IAC7D,SAAS,qEAAiD;IAE1D,IAAI,iDAAa;IAEjB,OAAO,CAAC,QAAQ,CAAC,OAAO,CAAmE;;IAoB3F,WAAW,CAAC,KAAK,EAAE,OAAO,CAAC,mBAAmB,CAAC;IAI/C,YAAY,CAAC,KAAK,EAAE,cAAc;IASlC,oBAAoB,CAAC,KAAK,EAAE,UAAU;yCA7C3B,aAAa;2CAAb,aAAa;CA+FzB"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { booleanAttribute, ChangeDetectionStrategy, Component, effect, ElementRef, inject, input, signal, ViewEncapsulation, } from "@angular/core";
|
|
1
|
+
import { booleanAttribute, ChangeDetectionStrategy, Component, DestroyRef, effect, ElementRef, inject, input, signal, ViewEncapsulation, } from "@angular/core";
|
|
2
2
|
import { useSdSystemConfigResource } from "../../../core/utils/useSdSystemConfigResource";
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
const _c0 = ["*"];
|
|
@@ -10,12 +10,17 @@ function SdDockControl_Conditional_1_Template(rf, ctx) { if (rf & 1) {
|
|
|
10
10
|
} }
|
|
11
11
|
export class SdDockControl {
|
|
12
12
|
_elRef = inject((ElementRef));
|
|
13
|
+
_destroyRef = inject(DestroyRef);
|
|
14
|
+
_dragCleanup;
|
|
13
15
|
key = input(...(ngDevMode ? [undefined, { debugName: "key" }] : /* istanbul ignore next */ []));
|
|
14
16
|
position = input("top", ...(ngDevMode ? [{ debugName: "position" }] : /* istanbul ignore next */ []));
|
|
15
17
|
resizable = input(false, { ...(ngDevMode ? { debugName: "resizable" } : /* istanbul ignore next */ {}), transform: booleanAttribute });
|
|
16
18
|
size = signal(0, ...(ngDevMode ? [{ debugName: "size" }] : /* istanbul ignore next */ []));
|
|
17
19
|
_config = useSdSystemConfigResource({ key: this.key });
|
|
18
20
|
constructor() {
|
|
21
|
+
this._destroyRef.onDestroy(() => {
|
|
22
|
+
this._dragCleanup?.();
|
|
23
|
+
});
|
|
19
24
|
effect(() => {
|
|
20
25
|
const conf = this._config.value();
|
|
21
26
|
if (this.resizable() && conf && conf.size != null) {
|
|
@@ -65,8 +70,7 @@ export class SdDockControl {
|
|
|
65
70
|
const stopDrag = (e) => {
|
|
66
71
|
e.stopPropagation();
|
|
67
72
|
e.preventDefault();
|
|
68
|
-
|
|
69
|
-
document.removeEventListener("mouseup", stopDrag);
|
|
73
|
+
this._dragCleanup?.();
|
|
70
74
|
if (this.key() != null) {
|
|
71
75
|
const newConf = {};
|
|
72
76
|
if (["right", "left"].includes(this.position())) {
|
|
@@ -80,6 +84,11 @@ export class SdDockControl {
|
|
|
80
84
|
};
|
|
81
85
|
document.addEventListener("mousemove", doDrag);
|
|
82
86
|
document.addEventListener("mouseup", stopDrag);
|
|
87
|
+
this._dragCleanup = () => {
|
|
88
|
+
document.removeEventListener("mousemove", doDrag);
|
|
89
|
+
document.removeEventListener("mouseup", stopDrag);
|
|
90
|
+
this._dragCleanup = undefined;
|
|
91
|
+
};
|
|
83
92
|
}
|
|
84
93
|
static ɵfac = function SdDockControl_Factory(__ngFactoryType__) { return new (__ngFactoryType__ || SdDockControl)(); };
|
|
85
94
|
static ɵcmp = /*@__PURE__*/ i0.ɵɵdefineComponent({ type: SdDockControl, selectors: [["sd-dock"]], hostVars: 2, hostBindings: function SdDockControl_HostBindings(rf, ctx) { if (rf & 1) {
|
|
@@ -108,4 +117,4 @@ export class SdDockControl {
|
|
|
108
117
|
}
|
|
109
118
|
`, styles: ["sd-dock {\n display: block;\n position: absolute;\n overflow: auto;\n}\nsd-dock[data-sd-resizable=true] > ._resize-bar {\n position: absolute;\n}\nsd-dock[data-sd-resizable=true][data-sd-position=top] > ._resize-bar {\n bottom: 0;\n left: 0;\n width: 100%;\n height: 2px;\n cursor: ns-resize;\n}\nsd-dock[data-sd-resizable=true][data-sd-position=bottom] > ._resize-bar {\n top: 0;\n left: 0;\n width: 100%;\n height: 2px;\n cursor: ns-resize;\n}\nsd-dock[data-sd-resizable=true][data-sd-position=left] > ._resize-bar {\n top: 0;\n right: 0;\n height: 100%;\n width: 2px;\n cursor: ew-resize;\n}\nsd-dock[data-sd-resizable=true][data-sd-position=right] > ._resize-bar {\n top: 0;\n left: 0;\n height: 100%;\n width: 2px;\n cursor: ew-resize;\n}"] }]
|
|
110
119
|
}], () => [], { key: [{ type: i0.Input, args: [{ isSignal: true, alias: "key", required: false }] }], position: [{ type: i0.Input, args: [{ isSignal: true, alias: "position", required: false }] }], resizable: [{ type: i0.Input, args: [{ isSignal: true, alias: "resizable", required: false }] }] }); })();
|
|
111
|
-
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SdDockControl, { className: "SdDockControl", filePath: "packages/angular/src/ui/layout/dock/sd-dock.control.ts", lineNumber:
|
|
120
|
+
(() => { (typeof ngDevMode === "undefined" || ngDevMode) && i0.ɵsetClassDebugInfo(SdDockControl, { className: "SdDockControl", filePath: "packages/angular/src/ui/layout/dock/sd-dock.control.ts", lineNumber: 89 }); })();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sd-kanban-lane.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\layout\\kanban\\sd-kanban-lane.control.ts"],"names":[],"mappings":"AACA,OAAO,EAYL,WAAW,EAEZ,MAAM,eAAe,CAAC;AAGvB,OAAO,EAEL,KAAK,m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S;IAU3B,SAAS,CAAC,QAAQ,CAAC,YAAY,wkBAAgB;IAC/C,SAAS,CAAC,QAAQ,CAAC,SAAS,ubAAa;yCA3F9B,mBAAmB;2CAAnB,mBAAmB;CA4F/B"}
|
|
@@ -79,7 +79,10 @@ export class SdKanbanLaneControl {
|
|
|
79
79
|
kanbanControls = contentChildren(SdKanbanControl, { ...(ngDevMode ? { debugName: "kanbanControls" } : /* istanbul ignore next */ {}), descendants: true });
|
|
80
80
|
toolTplRef = contentChild("toolTpl", { ...(ngDevMode ? { debugName: "toolTplRef" } : /* istanbul ignore next */ {}), read: TemplateRef });
|
|
81
81
|
titleTplRef = contentChild("titleTpl", { ...(ngDevMode ? { debugName: "titleTplRef" } : /* istanbul ignore next */ {}), read: TemplateRef });
|
|
82
|
-
isAllSelected = computed(() =>
|
|
82
|
+
isAllSelected = computed(() => {
|
|
83
|
+
const selectableControls = this.kanbanControls().filter((ctrl) => ctrl.selectable());
|
|
84
|
+
return selectableControls.length > 0 && selectableControls.every((ctrl) => ctrl.selected());
|
|
85
|
+
}, ...(ngDevMode ? [{ debugName: "isAllSelected" }] : /* istanbul ignore next */ []));
|
|
83
86
|
dragKanban = computed(() => this._boardControl.dragKanban(), ...(ngDevMode ? [{ debugName: "dragKanban" }] : /* istanbul ignore next */ []));
|
|
84
87
|
dragOvered = signal(false, ...(ngDevMode ? [{ debugName: "dragOvered" }] : /* istanbul ignore next */ []));
|
|
85
88
|
selectableKanbanLength = computed(() => this.kanbanControls().filter((ctrl) => ctrl.selectable()).length, ...(ngDevMode ? [{ debugName: "selectableKanbanLength" }] : /* istanbul ignore next */ []));
|
|
@@ -94,6 +97,8 @@ export class SdKanbanLaneControl {
|
|
|
94
97
|
this._boardControl.selectedValues.update((v) => {
|
|
95
98
|
const r = [...v];
|
|
96
99
|
for (const ctrl of this.kanbanControls()) {
|
|
100
|
+
if (!ctrl.selectable())
|
|
101
|
+
continue;
|
|
97
102
|
if (ctrl.value() == null)
|
|
98
103
|
continue;
|
|
99
104
|
if (!v.includes(ctrl.value())) {
|
|
@@ -106,6 +111,7 @@ export class SdKanbanLaneControl {
|
|
|
106
111
|
else {
|
|
107
112
|
this._boardControl.selectedValues.update((v) => {
|
|
108
113
|
const kanbanValues = this.kanbanControls()
|
|
114
|
+
.filter((ctrl) => ctrl.selectable())
|
|
109
115
|
.map((ctrl) => ctrl.value())
|
|
110
116
|
.filter((v2) => v2 != null);
|
|
111
117
|
const result = v.filter((item) => !kanbanValues.includes(item));
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import * as i0 from "@angular/core";
|
|
2
2
|
export declare class SdGapControl {
|
|
3
3
|
private readonly _elRef;
|
|
4
|
-
height: import("@angular/core").InputSignal<"default" | "
|
|
4
|
+
height: import("@angular/core").InputSignal<"default" | "sm" | "lg" | "xxs" | "xs" | "xl" | "xxl" | undefined>;
|
|
5
5
|
heightPx: import("@angular/core").InputSignal<number | undefined>;
|
|
6
|
-
width: import("@angular/core").InputSignal<"default" | "
|
|
6
|
+
width: import("@angular/core").InputSignal<"default" | "sm" | "lg" | "xxs" | "xs" | "xl" | "xxl" | undefined>;
|
|
7
7
|
widthPx: import("@angular/core").InputSignal<number | undefined>;
|
|
8
8
|
widthEm: import("@angular/core").InputSignal<number | undefined>;
|
|
9
9
|
constructor();
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sd-pagination.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\navigation\\pagination\\sd-pagination.control.ts"],"names":[],"mappings":";AAkBA,qBA2Ca,mBAAmB;IAC9B,KAAK;;;;;MAAsF;IAE3F,WAAW,8CAAY;IACvB,cAAc,oEAA4C;IAC1D,gBAAgB,oEAA6C;IAE7D,OAAO,CAAC,QAAQ,CAAC,UAAU,CAExB;IAEH,OAAO,0CAKJ;IAEH,OAAO,0CAOJ;IAEH,YAAY,2CAeT;IAEH,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAI5B,aAAa,IAAI,IAAI;IAIrB,aAAa,IAAI,IAAI;
|
|
1
|
+
{"version":3,"file":"sd-pagination.control.d.ts","sourceRoot":"","sources":["..\\..\\..\\..\\src\\ui\\navigation\\pagination\\sd-pagination.control.ts"],"names":[],"mappings":";AAkBA,qBA2Ca,mBAAmB;IAC9B,KAAK;;;;;MAAsF;IAE3F,WAAW,8CAAY;IACvB,cAAc,oEAA4C;IAC1D,gBAAgB,oEAA6C;IAE7D,OAAO,CAAC,QAAQ,CAAC,UAAU,CAExB;IAEH,OAAO,0CAKJ;IAEH,OAAO,0CAOJ;IAEH,YAAY,2CAeT;IAEH,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,IAAI;IAI5B,aAAa,IAAI,IAAI;IAIrB,aAAa,IAAI,IAAI;IAKrB,SAAS,IAAI,IAAI;IAIjB,QAAQ,IAAI,IAAI;yCA7DL,mBAAmB;2CAAnB,mBAAmB;CAiE/B"}
|