@brickclay-org/ui 0.1.64 → 0.1.66
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/index.d.ts
CHANGED
|
@@ -840,7 +840,7 @@ declare class BkGrid<T = any> {
|
|
|
840
840
|
static ɵcmp: i0.ɵɵComponentDeclaration<BkGrid<any>, "bk-grid", never, { "draggable": { "alias": "draggable"; "required": false; }; "columns": { "alias": "columns"; "required": false; }; "result": { "alias": "result"; "required": false; }; "actions": { "alias": "actions"; "required": false; }; "customClass": { "alias": "customClass"; "required": false; }; "actionIconClass": { "alias": "actionIconClass"; "required": false; }; "actionClass": { "alias": "actionClass"; "required": false; }; "showNoRecords": { "alias": "showNoRecords"; "required": false; }; "noRecordFoundHeight": { "alias": "noRecordFoundHeight"; "required": false; }; }, { "change": "change"; "actionClick": "actionClick"; "sortChange": "sortChange"; "dragDropChange": "dragDropChange"; }, never, never, true, never>;
|
|
841
841
|
}
|
|
842
842
|
|
|
843
|
-
declare class BkSelect implements ControlValueAccessor {
|
|
843
|
+
declare class BkSelect implements ControlValueAccessor, AfterViewInit, OnDestroy {
|
|
844
844
|
items: i0.InputSignal<any[]>;
|
|
845
845
|
bindLabel: i0.InputSignal<string>;
|
|
846
846
|
bindValue: i0.InputSignal<string>;
|
|
@@ -866,7 +866,7 @@ declare class BkSelect implements ControlValueAccessor {
|
|
|
866
866
|
disabled: i0.ModelSignal<boolean>;
|
|
867
867
|
loading: i0.InputSignal<boolean>;
|
|
868
868
|
closeOnSelect: i0.InputSignal<boolean>;
|
|
869
|
-
dropdownPosition: i0.InputSignal<"
|
|
869
|
+
dropdownPosition: i0.InputSignal<"bottom" | "top">;
|
|
870
870
|
hasError: boolean;
|
|
871
871
|
errorMessage: string;
|
|
872
872
|
appendToBody: i0.InputSignal<boolean>;
|
|
@@ -885,12 +885,17 @@ declare class BkSelect implements ControlValueAccessor {
|
|
|
885
885
|
optionsListContainer: ElementRef<HTMLDivElement>;
|
|
886
886
|
optionsRef: QueryList<ElementRef>;
|
|
887
887
|
controlWrapper: ElementRef<HTMLDivElement>;
|
|
888
|
+
chipsViewport?: ElementRef<HTMLDivElement>;
|
|
889
|
+
measureChips?: QueryList<ElementRef<HTMLElement>>;
|
|
890
|
+
measurePlus?: ElementRef<HTMLElement>;
|
|
888
891
|
private _value;
|
|
889
892
|
private static activeInstance;
|
|
890
893
|
isOpen: i0.WritableSignal<boolean>;
|
|
891
894
|
selectedOptions: i0.WritableSignal<any[]>;
|
|
892
895
|
searchTerm: i0.WritableSignal<string>;
|
|
893
896
|
markedIndex: i0.WritableSignal<number>;
|
|
897
|
+
visibleCount: i0.WritableSignal<number>;
|
|
898
|
+
private resizeObserver?;
|
|
894
899
|
dropdownStyle: i0.WritableSignal<{
|
|
895
900
|
top?: string;
|
|
896
901
|
bottom?: string;
|
|
@@ -900,6 +905,16 @@ declare class BkSelect implements ControlValueAccessor {
|
|
|
900
905
|
filteredItems: i0.Signal<any[]>;
|
|
901
906
|
isAllSelected: i0.Signal<boolean>;
|
|
902
907
|
constructor();
|
|
908
|
+
ngAfterViewInit(): void;
|
|
909
|
+
ngOnDestroy(): void;
|
|
910
|
+
private scheduleRecompute;
|
|
911
|
+
/**
|
|
912
|
+
* Measures the off-screen chip row and works out how many chips fit on a
|
|
913
|
+
* single line. If every chip fits, all of them are shown and no "+N" badge
|
|
914
|
+
* is rendered. Otherwise it keeps as many chips as fit while reserving space
|
|
915
|
+
* for the "+N" overflow badge.
|
|
916
|
+
*/
|
|
917
|
+
private recomputeVisibleChips;
|
|
903
918
|
resolveLabel(item: any): string;
|
|
904
919
|
resolveValue(item: any): any;
|
|
905
920
|
isItemSelected(item: any): boolean;
|
|
@@ -1926,7 +1941,7 @@ declare class BkHierarchicalSelect implements ControlValueAccessor {
|
|
|
1926
1941
|
/** When true, dropdown is positioned fixed and sized to the trigger (use inside modals/popups). */
|
|
1927
1942
|
appendToBody: i0.InputSignal<boolean>;
|
|
1928
1943
|
/** Open above or below the trigger (also used when appendToBody is true for fixed coordinates). */
|
|
1929
|
-
dropdownPosition: i0.InputSignal<"
|
|
1944
|
+
dropdownPosition: i0.InputSignal<"bottom" | "top">;
|
|
1930
1945
|
/** Key for option color (e.g. "color"). When set, option label and selected value use this color. */
|
|
1931
1946
|
colorKey: i0.InputSignal<string>;
|
|
1932
1947
|
/** Whether to show clear button when a value is selected. */
|
package/package.json
CHANGED
|
@@ -24,3 +24,12 @@
|
|
|
24
24
|
.checkbox.lg svg {
|
|
25
25
|
@apply size-[14px];
|
|
26
26
|
}
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
/*---- Focus State: consistent 1px ring (box-shadow = no layout shift) ---- */
|
|
30
|
+
/* Both :focus and :focus-visible render the same 1px ring so neither disturbs it */
|
|
31
|
+
.group:focus .checkbox,
|
|
32
|
+
.group:focus-visible .checkbox {
|
|
33
|
+
outline: none;
|
|
34
|
+
box-shadow: 0 0 0 1px #000; /* black */
|
|
35
|
+
}
|
package/src/lib/radio/radio.css
CHANGED
|
@@ -48,3 +48,12 @@
|
|
|
48
48
|
.radio.lg .tick {
|
|
49
49
|
@apply size-[14px] min-h-[14px] min-w-[14px];
|
|
50
50
|
}
|
|
51
|
+
|
|
52
|
+
|
|
53
|
+
/*---- Focus State: consistent 1px ring (box-shadow = no layout shift) ---- */
|
|
54
|
+
/* Both :focus and :focus-visible render the same 1px ring so neither disturbs it */
|
|
55
|
+
.group:focus .radio,
|
|
56
|
+
.group:focus-visible .radio {
|
|
57
|
+
outline: none;
|
|
58
|
+
box-shadow: 0 0 0 1px #000; /* black */
|
|
59
|
+
}
|
|
@@ -70,6 +70,30 @@
|
|
|
70
70
|
|
|
71
71
|
/* --- NEW: Multi Select Chips --- */
|
|
72
72
|
|
|
73
|
+
/* Visible single-line chip row; overflow collapses into the "+N" badge.
|
|
74
|
+
flex: 1 forces the row to span the full available width so that the width
|
|
75
|
+
we measure (clientWidth) is the real space available — not the shrink-to-fit
|
|
76
|
+
width of however many chips happen to be rendered right now. Without this the
|
|
77
|
+
measurement collapses with the content and the row can never grow to fill
|
|
78
|
+
the space. */
|
|
79
|
+
.bk-chips-viewport {
|
|
80
|
+
flex: 1 1 0%;
|
|
81
|
+
min-width: 0;
|
|
82
|
+
max-width: 100%;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
/* Off-screen measurement row: renders all chips so each one's natural width
|
|
86
|
+
can be read, without affecting the visible layout. */
|
|
87
|
+
.bk-chips-measure {
|
|
88
|
+
position: absolute;
|
|
89
|
+
top: 0;
|
|
90
|
+
left: 0;
|
|
91
|
+
visibility: hidden;
|
|
92
|
+
pointer-events: none;
|
|
93
|
+
white-space: nowrap;
|
|
94
|
+
z-index: -1;
|
|
95
|
+
}
|
|
96
|
+
|
|
73
97
|
/* Badge Item */
|
|
74
98
|
.bk-multi-badge-item {
|
|
75
99
|
@apply inline-flex items-center gap-1.5 px-1.5 py-0.5 bg-white border border-[#E3E3E7] rounded-[4px];
|