chrv-components 1.12.161 → 1.12.162
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/package.json
CHANGED
|
@@ -1297,7 +1297,19 @@ declare class ChrInputDataOverlay {
|
|
|
1297
1297
|
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChrInputDataOverlay, "chr-input-data-overlay", never, {}, {}, never, ["*"], true, never>;
|
|
1298
1298
|
}
|
|
1299
1299
|
|
|
1300
|
+
interface FileEntry {
|
|
1301
|
+
id: number;
|
|
1302
|
+
file: IFile;
|
|
1303
|
+
progress: number;
|
|
1304
|
+
error?: string;
|
|
1305
|
+
}
|
|
1306
|
+
/**
|
|
1307
|
+
* Custom File Input. Support multiple files, base64 encoding and per-file validation.
|
|
1308
|
+
* Disclaimer: this is an AI created input.
|
|
1309
|
+
*/
|
|
1300
1310
|
declare class ChrFileInputComponent extends ChrInputComponent implements ControlValueAccessor, OnInit {
|
|
1311
|
+
private readonly fileService;
|
|
1312
|
+
private nextFileId;
|
|
1301
1313
|
/**
|
|
1302
1314
|
* Types de fichiers autorisés (ex: "image/*,.pdf")
|
|
1303
1315
|
*/
|
|
@@ -1306,6 +1318,10 @@ declare class ChrFileInputComponent extends ChrInputComponent implements Control
|
|
|
1306
1318
|
* Autoriser la sélection de plusieurs fichiers
|
|
1307
1319
|
*/
|
|
1308
1320
|
readonly multiple: _angular_core.InputSignal<boolean>;
|
|
1321
|
+
/**
|
|
1322
|
+
* Convert selected files to data URLs before updating the form value
|
|
1323
|
+
*/
|
|
1324
|
+
readonly base64: _angular_core.InputSignal<boolean>;
|
|
1309
1325
|
/**
|
|
1310
1326
|
* Référence de l'input HTML type="file" masqué
|
|
1311
1327
|
*/
|
|
@@ -1314,12 +1330,14 @@ declare class ChrFileInputComponent extends ChrInputComponent implements Control
|
|
|
1314
1330
|
* État du glisser-déposer (Drag & Drop)
|
|
1315
1331
|
*/
|
|
1316
1332
|
readonly isDragging: _angular_core.WritableSignal<boolean>;
|
|
1333
|
+
private readonly fileEntries;
|
|
1334
|
+
private readonly validationRevision;
|
|
1317
1335
|
constructor();
|
|
1318
1336
|
ngOnInit(): void;
|
|
1319
1337
|
/**
|
|
1320
1338
|
* Signal calculé pour garantir la manipulation d'un tableau de fichiers
|
|
1321
1339
|
*/
|
|
1322
|
-
readonly files: _angular_core.Signal<
|
|
1340
|
+
readonly files: _angular_core.Signal<FileEntry[]>;
|
|
1323
1341
|
/**
|
|
1324
1342
|
* Ouvre la fenêtre native de sélection de fichiers
|
|
1325
1343
|
*/
|
|
@@ -1342,12 +1360,15 @@ declare class ChrFileInputComponent extends ChrInputComponent implements Control
|
|
|
1342
1360
|
* Suppression d'un fichier sélectionné
|
|
1343
1361
|
*/
|
|
1344
1362
|
removeFile(index: number, event?: Event): void;
|
|
1363
|
+
private updateValue;
|
|
1364
|
+
private isAcceptedFile;
|
|
1365
|
+
getFileValidationError(index: number): string | null;
|
|
1345
1366
|
/**
|
|
1346
1367
|
* Utilitaire pour afficher la taille en Ko/Mo
|
|
1347
1368
|
*/
|
|
1348
1369
|
formatFileSize(bytes: number): string;
|
|
1349
1370
|
static ɵfac: _angular_core.ɵɵFactoryDeclaration<ChrFileInputComponent, never>;
|
|
1350
|
-
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChrFileInputComponent, "chr-file-input", never, { "accept": { "alias": "accept"; "required": false; "isSignal": true; }; "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
1371
|
+
static ɵcmp: _angular_core.ɵɵComponentDeclaration<ChrFileInputComponent, "chr-file-input", never, { "accept": { "alias": "accept"; "required": false; "isSignal": true; }; "multiple": { "alias": "multiple"; "required": false; "isSignal": true; }; "base64": { "alias": "base64"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
1351
1372
|
}
|
|
1352
1373
|
|
|
1353
1374
|
declare class ChrPasswordInputComponent extends ChrInputComponent implements ControlValueAccessor {
|
|
Binary file
|