carriera-intern-components 0.0.92 → 0.0.94

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.
Files changed (42) hide show
  1. package/app/components/avatar/avatar.component.d.ts +1 -1
  2. package/app/components/document-preview/document-preview.component.d.ts +48 -9
  3. package/app/components/drop-zone/drop-zone.component.d.ts +6 -1
  4. package/app/components/input/input.component.d.ts +26 -22
  5. package/app/components/input/models/input.model.d.ts +2 -0
  6. package/app/components/input/pipes/filter-by-search.pipe.d.ts +9 -0
  7. package/app/models/appFile.model.d.ts +1 -1
  8. package/fesm2022/carriera-intern-components.mjs +313 -213
  9. package/fesm2022/carriera-intern-components.mjs.map +1 -1
  10. package/package.json +1 -1
  11. package/public/assets/icons/fuel-contact/cai-count.svg +3 -0
  12. package/public/assets/icons/general/cai-money-additional.svg +3 -0
  13. package/public/assets/json/icons.json +37 -30
  14. /package/public/assets/icons/{cai-arrow-primary-up.svg → arrows/cai-arrow-primary-up.svg} +0 -0
  15. /package/public/assets/icons/{cai-arrow-secondary-down.svg → arrows/cai-arrow-secondary-down.svg} +0 -0
  16. /package/public/assets/icons/{cai-arrow-secondary-left.svg → arrows/cai-arrow-secondary-left.svg} +0 -0
  17. /package/public/assets/icons/{cai-arrow-secondary-right.svg → arrows/cai-arrow-secondary-right.svg} +0 -0
  18. /package/public/assets/icons/{cai-people.svg → fuel-contact/cai-people.svg} +0 -0
  19. /package/public/assets/icons/{cai-share.svg → fuel-contact/cai-share.svg} +0 -0
  20. /package/public/assets/icons/{cai-checkmark.svg → general/cai-checkmark.svg} +0 -0
  21. /package/public/assets/icons/{cai-date.svg → general/cai-date.svg} +0 -0
  22. /package/public/assets/icons/{cai-email.svg → general/cai-email.svg} +0 -0
  23. /package/public/assets/icons/{cai-label.svg → general/cai-label.svg} +0 -0
  24. /package/public/assets/icons/{cai-money.svg → general/cai-money.svg} +0 -0
  25. /package/public/assets/icons/{cai-phone.svg → general/cai-phone.svg} +0 -0
  26. /package/public/assets/icons/{cai-sort-by.svg → general/cai-sort-by.svg} +0 -0
  27. /package/public/assets/icons/{cai-cancel.svg → interaction/cai-cancel.svg} +0 -0
  28. /package/public/assets/icons/{cai-dislike.svg → interaction/cai-dislike.svg} +0 -0
  29. /package/public/assets/icons/{cai-like.svg → interaction/cai-like.svg} +0 -0
  30. /package/public/assets/icons/{cai-minus.svg → interaction/cai-minus.svg} +0 -0
  31. /package/public/assets/icons/{cai-password-hidden.svg → interaction/cai-password-hidden.svg} +0 -0
  32. /package/public/assets/icons/{cai-password-key.svg → interaction/cai-password-key.svg} +0 -0
  33. /package/public/assets/icons/{cai-password-shown.svg → interaction/cai-password-shown.svg} +0 -0
  34. /package/public/assets/icons/{cai-plus.svg → interaction/cai-plus.svg} +0 -0
  35. /package/public/assets/icons/{cai-driver.svg → load/cai-driver.svg} +0 -0
  36. /package/public/assets/icons/{cai-load.svg → load/cai-load.svg} +0 -0
  37. /package/public/assets/icons/{cai-ltl-single.svg → load/cai-ltl-single.svg} +0 -0
  38. /package/public/assets/icons/{cai-delete.svg → menu/cai-delete.svg} +0 -0
  39. /package/public/assets/icons/{cai-download.svg → menu/cai-download.svg} +0 -0
  40. /package/public/assets/icons/{cai-reset.svg → menu/cai-reset.svg} +0 -0
  41. /package/public/assets/icons/{cai-status-warning-lite.svg → status/cai-status-warning-lite.svg} +0 -0
  42. /package/public/assets/icons/{cai-status-warning.svg → status/cai-status-warning.svg} +0 -0
@@ -14,7 +14,7 @@ export declare class AvatarComponent {
14
14
  * The size of the avatar in pixels.
15
15
  * @type {Size}
16
16
  */
17
- size: import("@angular/core").InputSignal<18 | 22 | 32 | 74 | 160>;
17
+ size: import("@angular/core").InputSignal<160 | 18 | 22 | 32 | 74>;
18
18
  /**
19
19
  * Whether the avatar should be rounded or not at sizes of 74px and 160px.
20
20
  * @type {boolean}
@@ -1,13 +1,27 @@
1
+ import { OnChanges, SimpleChanges } from '@angular/core';
1
2
  import { AppFile } from '../../models/appFile.model';
2
- import { NgbPopover } from '@ng-bootstrap/ng-bootstrap';
3
3
  import * as i0 from "@angular/core";
4
4
  /**
5
5
  * This component displays a preview of a document, including its name, size,
6
6
  * and provides actions to delete, download, and tag the document.
7
7
  */
8
- export declare class DocumentPreviewComponent {
8
+ export declare class DocumentPreviewComponent implements OnChanges {
9
+ coverMinimalMod: import("@angular/core").InputSignal<boolean>;
10
+ isCrop: import("@angular/core").WritableSignal<boolean>;
11
+ constructor();
12
+ ngOnChanges(changes: SimpleChanges): void;
13
+ /**
14
+ * Signal that controls whether the delete modal is visible.Used to confirm the file deletion.
15
+ */
9
16
  showDeleteModal: import("@angular/core").WritableSignal<boolean>;
10
- showTagModal: import("@angular/core").WritableSignal<boolean>;
17
+ /**
18
+ * Boolean flag indicating whether the tag popover is visible.Used to apply conditional styling or behavior.
19
+ */
20
+ showTag: boolean;
21
+ /**
22
+ * Currently selected tag for the document.
23
+ */
24
+ selectedTag: string;
11
25
  /**
12
26
  * The application file to be displayed in the preview. This is a required input.
13
27
  * @type {InputSignal<AppFile>}
@@ -33,27 +47,52 @@ export declare class DocumentPreviewComponent {
33
47
  * Handles the delete action. Emits the `fileName` of the current `file` via the `onDelete` output.
34
48
  */
35
49
  handleDelete(): void;
50
+ /**
51
+ * Cancels the delete operation and hides the confirmation modal.
52
+ */
36
53
  cancelDelete(): void;
54
+ /**
55
+ * Confirms the deletion and emits the `onDelete` event.
56
+ */
37
57
  confirmDelete(): void;
38
58
  /**
39
59
  * Handles the download action. Emits the `fileName` of the current `file` via the `onDownload` output.
40
60
  */
41
61
  handleDownload(): void;
42
62
  /**
43
- * Handles the tag action. Currently, it logs a message to the console.
44
- * A "TODO" indicates that further logic for tagging needs to be implemented here.
63
+ * Callback triggered when the tag popover is shown. Used to update internal state.
64
+ */
65
+ onTagShown(): void;
66
+ /**
67
+ * Callback triggered when the tag popover is hidden. Used to update internal state.
68
+ */
69
+ onTagHidden(): void;
70
+ /**
71
+ * List of available tags for labeling the document. These are selectable within the tag popover.
45
72
  */
46
- handleTag(popover: NgbPopover): void;
47
73
  tags: string[];
48
- onOutsideClick(event: MouseEvent): void;
49
- selectedTag: string;
74
+ /**
75
+ * Emits when a tag is selected or removed for the file.
76
+ * Contains the file name and the selected tag.
77
+ * @type {OutputEmitterRef<{ fileName: string; tag: string }>}
78
+ */
50
79
  onTagChange: import("@angular/core").OutputEmitterRef<{
51
80
  fileName: string;
52
81
  tag: string;
53
82
  }>;
83
+ /**
84
+ * Selects a tag and emits the `onTagChange` output.
85
+ * @param newTag The newly selected tag string.
86
+ */
54
87
  getTag(newTag: string): void;
88
+ /**
89
+ * Removes the currently selected tag. Does not emit an event — must be called manually.
90
+ */
55
91
  removeTag(): void;
92
+ /**
93
+ * Placeholder for handling document sharing. Currently logs the file name to the console.
94
+ */
56
95
  handleShare(): void;
57
96
  static ɵfac: i0.ɵɵFactoryDeclaration<DocumentPreviewComponent, never>;
58
- static ɵcmp: i0.ɵɵComponentDeclaration<DocumentPreviewComponent, "cai-document-preview", never, { "file": { "alias": "file"; "required": true; "isSignal": true; }; "viewMode": { "alias": "viewMode"; "required": true; "isSignal": true; }; }, { "onDelete": "onDelete"; "onDownload": "onDownload"; "onTagChange": "onTagChange"; }, never, never, true, never>;
97
+ static ɵcmp: i0.ɵɵComponentDeclaration<DocumentPreviewComponent, "cai-document-preview", never, { "coverMinimalMod": { "alias": "coverMinimalMod"; "required": false; "isSignal": true; }; "file": { "alias": "file"; "required": true; "isSignal": true; }; "viewMode": { "alias": "viewMode"; "required": true; "isSignal": true; }; }, { "onDelete": "onDelete"; "onDownload": "onDownload"; "onTagChange": "onTagChange"; }, never, never, true, never>;
59
98
  }
@@ -18,6 +18,9 @@ export declare class DropZoneComponent {
18
18
  croppedImage: SafeUrl | null;
19
19
  showCropper: import("@angular/core").WritableSignal<boolean>;
20
20
  isCropperReady: import("@angular/core").WritableSignal<boolean>;
21
+ originalImageWidth: number;
22
+ originalImageHeight: number;
23
+ smallView: import("@angular/core").WritableSignal<boolean>;
21
24
  coverUrl: string;
22
25
  profileUrl: string;
23
26
  logoUrl: string;
@@ -26,8 +29,10 @@ export declare class DropZoneComponent {
26
29
  cropHeight: import("@angular/core").WritableSignal<number>;
27
30
  cropWidth: import("@angular/core").WritableSignal<number>;
28
31
  driver: import("@angular/core").WritableSignal<Driver>;
32
+ inputRange: ElementRef<HTMLInputElement>;
29
33
  constructor(sanitizer: DomSanitizer);
30
34
  ngOnInit(): void;
35
+ ngAfterViewInit(): void;
31
36
  updateRangeBackground(input: HTMLInputElement): void;
32
37
  cropDimensions(): void;
33
38
  ratioHelper(): number;
@@ -37,7 +42,7 @@ export declare class DropZoneComponent {
37
42
  imageLoaded(image: LoadedImage): void;
38
43
  cropperReady(): void;
39
44
  loadImageFailed(): void;
40
- smallView: import("@angular/core").WritableSignal<boolean>;
45
+ onTransformChange(event: ImageTransform): void;
41
46
  cancelCrop(): void;
42
47
  submitCrop(): void;
43
48
  /**
@@ -8,10 +8,7 @@ import { Broker, CaiInputConfig, Contact, DepartmentContactsPair, DropdownOption
8
8
  import { Dispatch, DispatchBoard } from './models';
9
9
  import * as i0 from "@angular/core";
10
10
  /**
11
- * A reusable input component that integrates with Angular Forms and supports
12
- * various input types, including text, password (with reveal functionality),
13
- * and numbers (with formatting and step controls). It also provides error
14
- * message display and icon support.
11
+ * This component is a generic input component that can be used to create various types of inputs.
15
12
  */
16
13
  export declare class InputComponent implements ControlValueAccessor {
17
14
  ngControl: NgControl | null;
@@ -42,17 +39,19 @@ export declare class InputComponent implements ControlValueAccessor {
42
39
  - `mask`: A pattern string for input masking (e.g., `'(000) 000-0000'`).
43
40
  - `min`: Minimum value for number inputs.
44
41
  - `max`: Maximum value for number inputs or maximum length for text inputs.
42
+ - `step`: Step value for number inputs. Can also be `automatic` for automatic step calculation.
45
43
  - `withButtons`: If `true`, adds increment/decrement buttons for number inputs.
46
44
  - `autocomplete`: The HTML `autocomplete` attribute.
47
45
  - `disabled`: If `true`, the input is disabled (for use without reactive form).
48
46
  - `passwordRequirements`: If `true`, shows password requirements for password inputs.
49
47
  - `optionValue`: The value to use in the formControl for the selected option in the dropdown.
48
+ - `subContent`: An optional slot for additional content to be displayed next to the content the user is entering. (ex. lbs, months, etc.)
50
49
  */
51
50
  config: import("@angular/core").InputSignal<CaiInputConfig>;
52
51
  /**
53
52
  * Input property to hold the dropdown options.
54
53
  */
55
- options: import("@angular/core").InputSignal<Dispatch[] | DropdownOption[] | LabelOption[] | Broker[] | DispatchBoard[] | DepartmentContactsPair[] | Shipper[]>;
54
+ options: import("@angular/core").InputSignal<DispatchBoard[] | Dispatch[] | LabelOption[] | Broker[] | DropdownOption[] | DepartmentContactsPair[] | Shipper[]>;
56
55
  /**
57
56
  * Input property to hold the label colors for the label picker.
58
57
  */
@@ -72,7 +71,7 @@ export declare class InputComponent implements ControlValueAccessor {
72
71
  /**
73
72
  * A signal that holds the locally added options.
74
73
  */
75
- localOptions: import("@angular/core").WritableSignal<Dispatch[] | DropdownOption[] | LabelOption[] | Broker[] | DispatchBoard[] | DepartmentContactsPair[] | Shipper[]>;
74
+ localOptions: import("@angular/core").WritableSignal<DispatchBoard[] | Dispatch[] | LabelOption[] | Broker[] | DropdownOption[] | DepartmentContactsPair[] | Shipper[]>;
76
75
  /**
77
76
  * A signal that holds the currently selected option from the dropdown.
78
77
  * @type {Signal<DropdownOption | null>}
@@ -82,13 +81,31 @@ export declare class InputComponent implements ControlValueAccessor {
82
81
  * A signal that indicates whether a new option is being added.
83
82
  */
84
83
  isAdding: import("@angular/core").WritableSignal<boolean>;
84
+ /**
85
+ * A signal that holds the currently selected label from the label picker.
86
+ */
85
87
  selectedLabel: import("@angular/core").WritableSignal<LabelOption | null>;
88
+ /**
89
+ * A signal that holds the currently selected color from the label picker.
90
+ */
86
91
  selectedColor: import("@angular/core").WritableSignal<LabelColor>;
87
92
  isPickingColor: import("@angular/core").WritableSignal<boolean>;
93
+ /**
94
+ * A signal that holds the currently selected dispatch board from the dispatch board picker.
95
+ */
88
96
  selectedDispatch: import("@angular/core").WritableSignal<Dispatch | null>;
89
97
  foldedBoards: import("@angular/core").WritableSignal<number[]>;
98
+ /**
99
+ * A signal that holds the currently selected broker from the broker picker.
100
+ */
90
101
  selectedBroker: import("@angular/core").WritableSignal<Broker | null>;
102
+ /**
103
+ * A signal that holds the currently selected contact from the contact picker.
104
+ */
91
105
  selectedContact: import("@angular/core").WritableSignal<Contact | null>;
106
+ /**
107
+ * A signal that holds the currently selected shipper from the shipper picker.
108
+ */
92
109
  selectedShipper: import("@angular/core").WritableSignal<Shipper | null>;
93
110
  /**
94
111
  * A computed signal that indicates whether the placeholder selected option should be shown.
@@ -97,22 +114,9 @@ export declare class InputComponent implements ControlValueAccessor {
97
114
  /**
98
115
  * A computed signal that dynamically calculates the step value for number inputs.
99
116
  */
100
- step: import("@angular/core").Signal<1000 | 5000 | 10000 | 20000>;
117
+ step: import("@angular/core").Signal<number>;
118
+ combinedOptions: import("@angular/core").Signal<DispatchBoard[] | Dispatch[] | LabelOption[] | Broker[] | DropdownOption[] | DepartmentContactsPair[] | Shipper[]>;
101
119
  dispatchCount: import("@angular/core").Signal<number>;
102
- filteredDispatches: import("@angular/core").Signal<DispatchBoard[]>;
103
- /**
104
- * A computed signal that provides the current list of options to display in the dropdown.
105
- *
106
- * If `search` is `false`, it returns the full `dropdownOptions`.
107
- * If `search` is `true`, it filters `dropdownOptions` based on the `value` signal,
108
- * performing a case-insensitive partial text match.
109
- *
110
- */
111
- filteredOptions: import("@angular/core").Signal<DropdownOption[]>;
112
- filteredLabels: import("@angular/core").Signal<LabelOption[]>;
113
- filteredBrokers: import("@angular/core").Signal<Broker[]>;
114
- filteredContacts: import("@angular/core").Signal<DepartmentContactsPair[]>;
115
- filteredShippers: import("@angular/core").Signal<Shipper[]>;
116
120
  /**
117
121
  * An output signal that emits the value of the added option.
118
122
  */
@@ -122,7 +126,7 @@ export declare class InputComponent implements ControlValueAccessor {
122
126
  */
123
127
  onAdd: import("@angular/core").OutputEmitterRef<void>;
124
128
  /**
125
- * An output signal that emits the value of the changed dropdown option.
129
+ * An output signal that emits the `optionValue` or `id` of the changed dropdown option.
126
130
  */
127
131
  onSelectionChange: import("@angular/core").OutputEmitterRef<any>;
128
132
  inputRef: ElementRef<HTMLInputElement>;
@@ -10,11 +10,13 @@ export interface CaiInputConfig {
10
10
  dropdown?: boolean | 'dispatch' | 'ftl-dispatch' | 'label' | 'broker' | 'contact' | 'shipper';
11
11
  search?: boolean;
12
12
  add?: boolean;
13
+ subcontent?: string;
13
14
  placeholderBehavior?: 'dynamic' | 'fade' | 'static';
14
15
  label?: string;
15
16
  mask?: string;
16
17
  min?: number;
17
18
  max?: number;
19
+ step?: number | 'automatic';
18
20
  withButtons?: boolean;
19
21
  autocomplete?: string;
20
22
  list?: boolean;
@@ -0,0 +1,9 @@
1
+ import { PipeTransform } from '@angular/core';
2
+ import { Broker, CaiInputConfig, Contact, DepartmentContactsPair, Dispatch, DispatchBoard, DropdownOption, LabelOption, Shipper } from '../models';
3
+ import * as i0 from "@angular/core";
4
+ export declare class FilterBySearchPipe implements PipeTransform {
5
+ hasProperty<T extends object>(obj: T, prop: PropertyKey): prop is keyof T;
6
+ transform(options: DispatchBoard[] | Dispatch[] | LabelOption[] | Broker[] | Contact[] | DropdownOption[] | DepartmentContactsPair[] | Shipper[], value: string | undefined | null, type: CaiInputConfig['dropdown'], shouldSearch?: boolean, foldedBoards?: number[]): any[];
7
+ static ɵfac: i0.ɵɵFactoryDeclaration<FilterBySearchPipe, never>;
8
+ static ɵpipe: i0.ɵɵPipeDeclaration<FilterBySearchPipe, "filterBySearch", true>;
9
+ }
@@ -7,7 +7,7 @@ export interface AppFile {
7
7
  size: number;
8
8
  imagePreviewUrl?: string;
9
9
  pageCount?: number;
10
- file: File;
10
+ file: File | null;
11
11
  tag: string;
12
12
  }
13
13
  export {};