@rlucan/ui 14.2.4 → 14.2.5
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/esm2020/lib/action-button/action-button.component.mjs +7 -4
- package/esm2020/lib/autocomplete/autocomplete.component.mjs +1 -1
- package/esm2020/lib/currency/currency.component.mjs +1 -1
- package/esm2020/lib/date/date.component.mjs +10 -6
- package/esm2020/lib/file/file.component.mjs +61 -4
- package/esm2020/lib/file-uploader/ui-file-uploader.component.mjs +3 -3
- package/esm2020/lib/input/input.component.mjs +34 -34
- package/esm2020/lib/select/select.component.mjs +2 -2
- package/esm2020/lib/services/message-box.service.mjs +45 -9
- package/esm2020/lib/text-area/text-area.component.mjs +2 -2
- package/fesm2015/rlucan-ui.mjs +247 -148
- package/fesm2015/rlucan-ui.mjs.map +1 -1
- package/fesm2020/rlucan-ui.mjs +242 -146
- package/fesm2020/rlucan-ui.mjs.map +1 -1
- package/lib/action-button/action-button.component.d.ts +0 -1
- package/lib/date/date.component.d.ts +1 -0
- package/lib/file/file.component.d.ts +6 -0
- package/lib/input/input.component.d.ts +16 -4
- package/lib/services/message-box.service.d.ts +16 -0
- package/package.json +1 -1
- package/scss/ui-defaults.scss +18 -3
- package/ui.scss +29 -6
|
@@ -13,11 +13,17 @@ export declare class FileComponent implements OnInit, OnChanges {
|
|
|
13
13
|
src: string;
|
|
14
14
|
mimeType?: string;
|
|
15
15
|
};
|
|
16
|
+
get fitImageFileSize(): boolean;
|
|
16
17
|
visible: boolean;
|
|
17
18
|
src: any;
|
|
18
19
|
srcUrlMimeType: any;
|
|
20
|
+
nativeFileSizeRatio: number;
|
|
21
|
+
nativeFileWidth: any;
|
|
22
|
+
nativeFileHeight: any;
|
|
19
23
|
get width(): string;
|
|
24
|
+
get maxWidth(): string;
|
|
20
25
|
get height(): string;
|
|
26
|
+
get maxHeight(): string;
|
|
21
27
|
get isVideo(): any;
|
|
22
28
|
get mime(): any;
|
|
23
29
|
get useRetinaSrc(): boolean;
|
|
@@ -2,18 +2,29 @@ import { ElementRef, EventEmitter, OnInit } from '@angular/core';
|
|
|
2
2
|
import { AbstractControl, ControlContainer, ValidationErrors } from '@angular/forms';
|
|
3
3
|
import { UiSimpleComponent } from '../simple/ui-simple.component';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
|
+
declare type PrefixSuffix = {
|
|
6
|
+
icon: string;
|
|
7
|
+
tooltip?: string;
|
|
8
|
+
};
|
|
5
9
|
export declare class InputComponent extends UiSimpleComponent implements OnInit {
|
|
6
10
|
protected controlContainer: ControlContainer;
|
|
7
|
-
|
|
8
|
-
|
|
11
|
+
prefixIcon: PrefixSuffix;
|
|
12
|
+
suffixIcon: PrefixSuffix;
|
|
9
13
|
type: 'text' | 'number' | 'password';
|
|
10
14
|
clearButton: boolean;
|
|
11
|
-
|
|
15
|
+
activeIcons: boolean;
|
|
16
|
+
forceHasPrefix: boolean;
|
|
17
|
+
forceHasSuffix: boolean;
|
|
12
18
|
centered: boolean;
|
|
13
19
|
input: ElementRef | undefined;
|
|
20
|
+
prefix: ElementRef | undefined;
|
|
21
|
+
suffix: ElementRef | undefined;
|
|
14
22
|
focusChanged: EventEmitter<boolean>;
|
|
15
23
|
keyPressed: EventEmitter<KeyboardEvent>;
|
|
24
|
+
get hasPrefix(): boolean;
|
|
25
|
+
get hasSuffix(): boolean;
|
|
16
26
|
required: boolean;
|
|
27
|
+
hasFocus: boolean;
|
|
17
28
|
value: string;
|
|
18
29
|
get maxLenRequired(): boolean;
|
|
19
30
|
constructor(controlContainer: ControlContainer);
|
|
@@ -25,5 +36,6 @@ export declare class InputComponent extends UiSimpleComponent implements OnInit
|
|
|
25
36
|
onKeypressed($event: any): void;
|
|
26
37
|
validate(control: AbstractControl): ValidationErrors | null;
|
|
27
38
|
static ɵfac: i0.ɵɵFactoryDeclaration<InputComponent, [{ optional: true; host: true; skipSelf: true; }]>;
|
|
28
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "ui-input", never, { "
|
|
39
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<InputComponent, "ui-input", never, { "prefixIcon": "prefixIcon"; "suffixIcon": "suffixIcon"; "type": "type"; "clearButton": "clearButton"; "activeIcons": "activeIcons"; "forceHasPrefix": "forceHasPrefix"; "forceHasSuffix": "forceHasSuffix"; "centered": "centered"; }, { "focusChanged": "focusChanged"; "keyPressed": "keyPressed"; }, never, ["[slot=prefix]", "[slot=suffix]"], false, never>;
|
|
29
40
|
}
|
|
41
|
+
export {};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { TemplateRef } from '@angular/core';
|
|
1
2
|
import { DomSanitizer } from '@angular/platform-browser';
|
|
2
3
|
import { MatDialog, MatDialogRef } from '@angular/material/dialog';
|
|
3
4
|
import { Observable } from 'rxjs';
|
|
@@ -8,6 +9,8 @@ export interface MessageBoxButton {
|
|
|
8
9
|
text: string;
|
|
9
10
|
kind?: 'basic' | 'flat' | 'stroked';
|
|
10
11
|
color?: 'primary' | 'accent' | 'warn';
|
|
12
|
+
process?: () => Promise<any>;
|
|
13
|
+
disabled?: () => boolean;
|
|
11
14
|
}
|
|
12
15
|
export declare class MessageBoxModalComponent {
|
|
13
16
|
dialogRef: MatDialogRef<MessageBoxModalComponent>;
|
|
@@ -18,9 +21,12 @@ export declare class MessageBoxModalComponent {
|
|
|
18
21
|
errorDetail: any;
|
|
19
22
|
buttons: MessageBoxButton[];
|
|
20
23
|
title: string;
|
|
24
|
+
template: any;
|
|
21
25
|
hideCloseButton: boolean;
|
|
26
|
+
processing: MessageBoxButton;
|
|
22
27
|
constructor(dialogRef: MatDialogRef<MessageBoxModalComponent>, sanitizer: DomSanitizer, data: any);
|
|
23
28
|
close(result: any): void;
|
|
29
|
+
buttonClick(b: MessageBoxButton): void;
|
|
24
30
|
static ɵfac: i0.ɵɵFactoryDeclaration<MessageBoxModalComponent, never>;
|
|
25
31
|
static ɵcmp: i0.ɵɵComponentDeclaration<MessageBoxModalComponent, "ui-message-box-modal", never, {}, {}, never, never, false, never>;
|
|
26
32
|
}
|
|
@@ -36,6 +42,16 @@ export declare class MessageBoxService {
|
|
|
36
42
|
hideCloseButton?: boolean;
|
|
37
43
|
maxWidth?: string;
|
|
38
44
|
}): Observable<any>;
|
|
45
|
+
open(options?: {
|
|
46
|
+
buttons?: MessageBoxButton[];
|
|
47
|
+
title?: string;
|
|
48
|
+
errorMessage?: string;
|
|
49
|
+
errorDetail?: string;
|
|
50
|
+
hideCloseButton?: boolean;
|
|
51
|
+
maxWidth?: string;
|
|
52
|
+
message?: string;
|
|
53
|
+
template?: TemplateRef<any>;
|
|
54
|
+
}): Observable<any>;
|
|
39
55
|
confirmDelete(title: string, message: string): Observable<any>;
|
|
40
56
|
static ɵfac: i0.ɵɵFactoryDeclaration<MessageBoxService, never>;
|
|
41
57
|
static ɵprov: i0.ɵɵInjectableDeclaration<MessageBoxService>;
|
package/package.json
CHANGED
package/scss/ui-defaults.scss
CHANGED
|
@@ -276,10 +276,25 @@
|
|
|
276
276
|
placeholder: (
|
|
277
277
|
color: rgba($baseTextColor, 0.60)
|
|
278
278
|
),
|
|
279
|
-
|
|
280
|
-
color:
|
|
279
|
+
clear-icon: (
|
|
280
|
+
color: yellow,
|
|
281
281
|
hover: (
|
|
282
|
-
color:
|
|
282
|
+
color: pink
|
|
283
|
+
)
|
|
284
|
+
),
|
|
285
|
+
prefix-suffix: (
|
|
286
|
+
color: mat.get-color-from-palette($primaryPalette, 100),
|
|
287
|
+
focus: (
|
|
288
|
+
color: $primaryColor
|
|
289
|
+
),
|
|
290
|
+
active: (
|
|
291
|
+
color: $primaryColor,
|
|
292
|
+
hover: (
|
|
293
|
+
color: mat.get-color-from-palette($primaryPalette, 800),
|
|
294
|
+
),
|
|
295
|
+
disabled: (
|
|
296
|
+
color: mat.get-color-from-palette(mat.$light-theme-foreground-palette, disabled-text)
|
|
297
|
+
)
|
|
283
298
|
)
|
|
284
299
|
),
|
|
285
300
|
),
|
package/ui.scss
CHANGED
|
@@ -126,10 +126,32 @@
|
|
|
126
126
|
|
|
127
127
|
ui-input, ui-date {
|
|
128
128
|
.control-container {
|
|
129
|
-
|
|
130
|
-
color: uiGetColor($colors, "input.
|
|
129
|
+
.xxxclear-icon {
|
|
130
|
+
color: uiGetColor($colors, "input.clear-icon.color");
|
|
131
131
|
&:hover {
|
|
132
|
-
color: uiGetColor($colors, "input.
|
|
132
|
+
color: uiGetColor($colors, "input.clear-icon.hover.color");
|
|
133
|
+
}
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
.control-container.active-icons {
|
|
137
|
+
[slot=suffix], [slot=prefix], .prefix-icon, .suffix-icon {
|
|
138
|
+
color: uiGetColor($colors, "input.prefix-suffix.active.color");
|
|
139
|
+
&.disabled {
|
|
140
|
+
color: uiGetColor($colors, "input.prefix-suffix.active.disabled.color");
|
|
141
|
+
}
|
|
142
|
+
&:not(.disabled):hover {
|
|
143
|
+
color: uiGetColor($colors, "input.prefix-suffix.active.hover.color");
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
.control-container:not(.active-icons) {
|
|
149
|
+
[slot=suffix], [slot=prefix], .prefix-icon, .suffix-icon {
|
|
150
|
+
color: uiGetColor($colors, "input.prefix-suffix.color");
|
|
151
|
+
}
|
|
152
|
+
&.has-focus {
|
|
153
|
+
[slot=suffix], [slot=prefix], .prefix-icon, .suffix-icon {
|
|
154
|
+
color: uiGetColor($colors, "input.prefix-suffix.focus.color");
|
|
133
155
|
}
|
|
134
156
|
}
|
|
135
157
|
}
|
|
@@ -807,6 +829,7 @@ ui-button, ui-action-button, ui-input, ui-date, ui-text-area, ui-select, ui-radi
|
|
|
807
829
|
width: calc(2.5em / 2);
|
|
808
830
|
height: calc(2.5em / 2);
|
|
809
831
|
flex: 0 0 calc(2.5em / 2);
|
|
832
|
+
margin: calc(-1 * 2.5em / 4) !important;
|
|
810
833
|
}
|
|
811
834
|
.mdc-checkbox__background {
|
|
812
835
|
height: calc(2.5em / 2);
|
|
@@ -890,9 +913,9 @@ ui-button, ui-action-button, ui-input, ui-date, ui-text-area, ui-select, ui-radi
|
|
|
890
913
|
}
|
|
891
914
|
|
|
892
915
|
.mat-mdc-checkbox {
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
}
|
|
916
|
+
//.mdc-checkbox {
|
|
917
|
+
// margin: -0.5em !important;
|
|
918
|
+
//}
|
|
896
919
|
&.mat-mdc-checkbox-disabled {
|
|
897
920
|
opacity: 0.38;
|
|
898
921
|
//label {
|