ud-components 0.4.2 → 0.4.3

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.
@@ -53,4 +53,13 @@ export interface TableDisplayColumn {
53
53
  * Useful in cases where were not sending the whole object to the client but still need to filter
54
54
  */
55
55
  filterProperty?: string;
56
+ /**
57
+ * Fixed pixel width for the column. Takes priority over widthRatio.
58
+ */
59
+ widthPixel?: number;
60
+ /**
61
+ * Relative width ratio. Columns without either width property default to 1.
62
+ * e.g. a column with ratio 2 gets twice the width of a column with ratio 1.
63
+ */
64
+ widthRatio?: number;
56
65
  }
@@ -1,6 +1,6 @@
1
1
  import * as i0 from "@angular/core";
2
2
  export type UdButtonVariant = 'flat' | 'stroked' | 'icon-only';
3
- export type UdButtonColor = 'primary' | 'secondary' | 'danger' | 'success';
3
+ export type UdButtonColor = 'primary' | 'secondary' | 'danger' | 'success' | 'warning' | 'info';
4
4
  export type UdButtonSize = 'sm' | 'md' | 'lg';
5
5
  export type UdButtonIconPosition = 'left' | 'right';
6
6
  /**
@@ -0,0 +1,32 @@
1
+ import { OnChanges, SimpleChanges } from '@angular/core';
2
+ import { ControlValueAccessor } from '@angular/forms';
3
+ import * as i0 from "@angular/core";
4
+ export interface ButtonToggleOption {
5
+ value: any;
6
+ label?: string;
7
+ icon?: string;
8
+ }
9
+ export type ButtonToggleSize = 'sm' | 'md' | 'lg';
10
+ /**
11
+ * Segmented button toggle group. Works with [(ngModel)] and reactive forms.
12
+ *
13
+ * Usage:
14
+ * <ud-button-toggle [(ngModel)]="selected" [options]="opts" />
15
+ * <ud-button-toggle [(ngModel)]="selected" [options]="opts" size="sm" />
16
+ */
17
+ export declare class UdButtonToggleComponent implements ControlValueAccessor, OnChanges {
18
+ options: ButtonToggleOption[];
19
+ size: ButtonToggleSize;
20
+ disabled: boolean;
21
+ value: any;
22
+ private onChange;
23
+ private onTouched;
24
+ ngOnChanges(changes: SimpleChanges): void;
25
+ select(option: ButtonToggleOption): void;
26
+ writeValue(v: any): void;
27
+ registerOnChange(fn: (v: any) => void): void;
28
+ registerOnTouched(fn: () => void): void;
29
+ setDisabledState(isDisabled: boolean): void;
30
+ static ɵfac: i0.ɵɵFactoryDeclaration<UdButtonToggleComponent, never>;
31
+ static ɵcmp: i0.ɵɵComponentDeclaration<UdButtonToggleComponent, "ud-button-toggle", never, { "options": { "alias": "options"; "required": true; }; "size": { "alias": "size"; "required": false; }; "disabled": { "alias": "disabled"; "required": false; }; }, {}, never, never, true, never>;
32
+ }
@@ -207,7 +207,7 @@ export declare class CustomTableComponent implements OnInit {
207
207
  private isApplicationSubmitted;
208
208
  get hasSelectedRow(): boolean;
209
209
  get actionColumnStyleWidth(): string;
210
- get generalColumnStyleWidth(): string;
210
+ getColumnWidth(column: TableDisplayColumn): string;
211
211
  get displayedColumnsProperty(): string[];
212
212
  get displayedColumnsWithoutSelect(): TableDisplayColumn[];
213
213
  get displayCheckbox(): boolean;
@@ -0,0 +1,8 @@
1
+ import * as i0 from "@angular/core";
2
+ export declare class UdPreviewContainerComponent {
3
+ title: string;
4
+ icon?: string;
5
+ padding: string;
6
+ static ɵfac: i0.ɵɵFactoryDeclaration<UdPreviewContainerComponent, never>;
7
+ static ɵcmp: i0.ɵɵComponentDeclaration<UdPreviewContainerComponent, "ud-preview-container", never, { "title": { "alias": "title"; "required": false; }; "icon": { "alias": "icon"; "required": false; }; "padding": { "alias": "padding"; "required": false; }; }, {}, never, ["*"], true, never>;
8
+ }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ud-components",
3
- "version": "0.4.2",
3
+ "version": "0.4.3",
4
4
  "peerDependencies": {
5
5
  "@angular/common": ">=19",
6
6
  "@angular/core": ">=19",
package/public-api.d.ts CHANGED
@@ -23,6 +23,8 @@ export * from './lib/form-fields/time-picker/time-picker.component';
23
23
  export * from './lib/form-fields/textarea/textarea.component';
24
24
  export * from './lib/form-fields/phone-input/phone-input.component';
25
25
  export * from './lib/button/button.component';
26
+ export * from './lib/button-toggle/button-toggle.component';
27
+ export * from './lib/preview-container/preview-container.component';
26
28
  export * from './lib/toggle/toggle.component';
27
29
  export * from './enums/loading-status.enum';
28
30
  export * from './enums/application-status.enum';