@lucca-front/ng 22.0.0-rc.2 → 22.0.0-rc.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.
Files changed (80) hide show
  1. package/fesm2022/lucca-front-ng-api.mjs +160 -85
  2. package/fesm2022/lucca-front-ng-api.mjs.map +1 -1
  3. package/fesm2022/lucca-front-ng-clear.mjs +7 -6
  4. package/fesm2022/lucca-front-ng-clear.mjs.map +1 -1
  5. package/fesm2022/lucca-front-ng-core-select-api.mjs +37 -21
  6. package/fesm2022/lucca-front-ng-core-select-api.mjs.map +1 -1
  7. package/fesm2022/lucca-front-ng-core-select-user.mjs +2 -2
  8. package/fesm2022/lucca-front-ng-core-select-user.mjs.map +1 -1
  9. package/fesm2022/lucca-front-ng-core-select.mjs +229 -135
  10. package/fesm2022/lucca-front-ng-core-select.mjs.map +1 -1
  11. package/fesm2022/lucca-front-ng-core.mjs +1 -12
  12. package/fesm2022/lucca-front-ng-core.mjs.map +1 -1
  13. package/fesm2022/lucca-front-ng-date.mjs +124 -100
  14. package/fesm2022/lucca-front-ng-date.mjs.map +1 -1
  15. package/fesm2022/lucca-front-ng-date2.mjs +37 -25
  16. package/fesm2022/lucca-front-ng-date2.mjs.map +1 -1
  17. package/fesm2022/lucca-front-ng-department.mjs +0 -2
  18. package/fesm2022/lucca-front-ng-department.mjs.map +1 -1
  19. package/fesm2022/lucca-front-ng-divider.mjs +6 -4
  20. package/fesm2022/lucca-front-ng-divider.mjs.map +1 -1
  21. package/fesm2022/lucca-front-ng-dropdown.mjs +34 -31
  22. package/fesm2022/lucca-front-ng-dropdown.mjs.map +1 -1
  23. package/fesm2022/lucca-front-ng-establishment.mjs +83 -49
  24. package/fesm2022/lucca-front-ng-establishment.mjs.map +1 -1
  25. package/fesm2022/lucca-front-ng-filter-pills.mjs +18 -8
  26. package/fesm2022/lucca-front-ng-filter-pills.mjs.map +1 -1
  27. package/fesm2022/lucca-front-ng-form-field.mjs +10 -7
  28. package/fesm2022/lucca-front-ng-form-field.mjs.map +1 -1
  29. package/fesm2022/lucca-front-ng-formly.mjs +2 -3
  30. package/fesm2022/lucca-front-ng-formly.mjs.map +1 -1
  31. package/fesm2022/lucca-front-ng-forms.mjs +46 -5
  32. package/fesm2022/lucca-front-ng-forms.mjs.map +1 -1
  33. package/fesm2022/lucca-front-ng-input.mjs +0 -1
  34. package/fesm2022/lucca-front-ng-input.mjs.map +1 -1
  35. package/fesm2022/lucca-front-ng-modal.mjs +15 -11
  36. package/fesm2022/lucca-front-ng-modal.mjs.map +1 -1
  37. package/fesm2022/lucca-front-ng-multi-select.mjs +115 -91
  38. package/fesm2022/lucca-front-ng-multi-select.mjs.map +1 -1
  39. package/fesm2022/lucca-front-ng-number-format.mjs +11 -7
  40. package/fesm2022/lucca-front-ng-number-format.mjs.map +1 -1
  41. package/fesm2022/lucca-front-ng-option.mjs +37 -30
  42. package/fesm2022/lucca-front-ng-option.mjs.map +1 -1
  43. package/fesm2022/lucca-front-ng-popover.mjs +238 -123
  44. package/fesm2022/lucca-front-ng-popover.mjs.map +1 -1
  45. package/fesm2022/lucca-front-ng-popover2.mjs +65 -37
  46. package/fesm2022/lucca-front-ng-popover2.mjs.map +1 -1
  47. package/fesm2022/lucca-front-ng-select.mjs +123 -76
  48. package/fesm2022/lucca-front-ng-select.mjs.map +1 -1
  49. package/fesm2022/lucca-front-ng-sidepanel.mjs.map +1 -1
  50. package/fesm2022/lucca-front-ng-simple-select.mjs +13 -13
  51. package/fesm2022/lucca-front-ng-simple-select.mjs.map +1 -1
  52. package/fesm2022/lucca-front-ng-time.mjs +8 -6
  53. package/fesm2022/lucca-front-ng-time.mjs.map +1 -1
  54. package/fesm2022/lucca-front-ng-user-popover.mjs +13 -9
  55. package/fesm2022/lucca-front-ng-user-popover.mjs.map +1 -1
  56. package/fesm2022/lucca-front-ng-user.mjs +93 -59
  57. package/fesm2022/lucca-front-ng-user.mjs.map +1 -1
  58. package/package.json +4 -4
  59. package/types/lucca-front-ng-api.d.ts +62 -62
  60. package/types/lucca-front-ng-clear.d.ts +2 -3
  61. package/types/lucca-front-ng-core-select-api.d.ts +22 -22
  62. package/types/lucca-front-ng-core-select.d.ts +139 -140
  63. package/types/lucca-front-ng-core.d.ts +2 -7
  64. package/types/lucca-front-ng-date.d.ts +26 -28
  65. package/types/lucca-front-ng-divider.d.ts +1 -1
  66. package/types/lucca-front-ng-dropdown.d.ts +4 -5
  67. package/types/lucca-front-ng-establishment.d.ts +19 -18
  68. package/types/lucca-front-ng-form-field.d.ts +3 -2
  69. package/types/lucca-front-ng-forms.d.ts +32 -12
  70. package/types/lucca-front-ng-modal.d.ts +2 -2
  71. package/types/lucca-front-ng-multi-select.d.ts +37 -36
  72. package/types/lucca-front-ng-option.d.ts +10 -10
  73. package/types/lucca-front-ng-popover.d.ts +46 -52
  74. package/types/lucca-front-ng-popover2.d.ts +11 -13
  75. package/types/lucca-front-ng-segmented-control.d.ts +4 -2
  76. package/types/lucca-front-ng-select.d.ts +28 -30
  77. package/types/lucca-front-ng-simple-select.d.ts +3 -3
  78. package/types/lucca-front-ng-time.d.ts +1 -1
  79. package/types/lucca-front-ng-user-popover.d.ts +3 -4
  80. package/types/lucca-front-ng-user.d.ts +20 -20
@@ -1,6 +1,6 @@
1
1
  import { isNil } from '@lucca-front/ng/core';
2
2
  import * as i0 from '@angular/core';
3
- import { Pipe, inject, ElementRef, Renderer2, signal, input, computed, forwardRef, Directive } from '@angular/core';
3
+ import { Pipe, inject, ElementRef, Renderer2, signal, input, computed, forwardRef, HostListener, Directive } from '@angular/core';
4
4
  import { NG_VALUE_ACCESSOR } from '@angular/forms';
5
5
 
6
6
  function joinSplittedInput({ minusSign, integer, delimiter, fraction }) {
@@ -262,11 +262,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
262
262
  type: Directive,
263
263
  args: [{
264
264
  selector: 'input[luNumberFormatInput]',
265
- host: {
266
- '(focus)': 'focus()',
267
- '(blur)': 'lostFocus()',
268
- '(input)': 'input()',
269
- },
270
265
  providers: [
271
266
  {
272
267
  provide: NG_VALUE_ACCESSOR,
@@ -275,7 +270,16 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
275
270
  },
276
271
  ],
277
272
  }]
278
- }], propDecorators: { formatOptions: [{ type: i0.Input, args: [{ isSignal: true, alias: "formatOptions", required: true }] }] } });
273
+ }], propDecorators: { formatOptions: [{ type: i0.Input, args: [{ isSignal: true, alias: "formatOptions", required: true }] }], focus: [{
274
+ type: HostListener,
275
+ args: ['focus']
276
+ }], lostFocus: [{
277
+ type: HostListener,
278
+ args: ['blur']
279
+ }], input: [{
280
+ type: HostListener,
281
+ args: ['input']
282
+ }] } });
279
283
 
280
284
  /**
281
285
  * Generated bundle index. Do not edit.
@@ -1 +1 @@
1
- {"version":3,"file":"lucca-front-ng-number-format.mjs","sources":["../../../packages/ng/number-format/number-format.models.ts","../../../packages/ng/number-format/number-format.ts","../../../packages/ng/number-format/number-format.pipe.ts","../../../packages/ng/number-format/number-format.directive.ts","../../../packages/ng/number-format/lucca-front-ng-number-format.ts"],"sourcesContent":["export type NumberFormatStyle = 'decimal' | 'currency' | 'percent' | 'unit';\n\nexport type NumberFormatUnit =\n\t| 'acre'\n\t| 'bit'\n\t| 'byte'\n\t| 'celsius'\n\t| 'centimeter'\n\t| 'day'\n\t| 'degree'\n\t| 'fahrenheit'\n\t| 'fluid-ounce'\n\t| 'foot'\n\t| 'gallon'\n\t| 'gigabit'\n\t| 'gigabyte'\n\t| 'gram'\n\t| 'hectare'\n\t| 'hour'\n\t| 'inch'\n\t| 'kilobit'\n\t| 'kilobyte'\n\t| 'kilogram'\n\t| 'kilometer'\n\t| 'liter'\n\t| 'megabit'\n\t| 'megabyte'\n\t| 'meter'\n\t| 'microsecond'\n\t| 'mile'\n\t| 'mile-scandinavian'\n\t| 'milliliter'\n\t| 'millimeter'\n\t| 'millisecond'\n\t| 'minute'\n\t| 'month'\n\t| 'nanosecond'\n\t| 'ounce'\n\t| 'percent'\n\t| 'petabyte'\n\t| 'pound'\n\t| 'second'\n\t| 'stone'\n\t| 'terabit'\n\t| 'terabyte'\n\t| 'week'\n\t| 'yard'\n\t| 'year';\n\nexport type NumberFormatUnitDisplay = 'short' | 'narrow' | 'long';\n\nexport type NumberFormatCurrencyDisplay = 'code' | 'symbol' | 'narrowSymbol' | 'name';\n\nexport interface NumberFormatOptions {\n\tlocale: string;\n\tmin?: number | undefined;\n\tmax?: number | undefined;\n\tstyle: NumberFormatStyle;\n\tcurrency?: string | undefined;\n\tcurrencyDisplay?: NumberFormatCurrencyDisplay | undefined;\n\tunit?: NumberFormatUnit | undefined;\n\tunitDisplay?: NumberFormatUnitDisplay | undefined;\n\tuseGrouping?: boolean | undefined;\n\tminimumIntegerDigits?: number | undefined;\n\tminimumFractionDigits?: number | undefined;\n\tmaximumFractionDigits?: number | undefined;\n\tminimumSignificantDigits?: number | undefined;\n\tmaximumSignificantDigits?: number | undefined;\n}\n\nexport interface NumberFormatSplittedInput {\n\tminusSign: string;\n\tinteger: string;\n\tdelimiter: string;\n\tfraction: string;\n}\n\nexport interface NumberFormatParsedInput {\n\tsplittedInput: NumberFormatSplittedInput;\n\tcleanInput: string;\n\tvalue: number | null;\n}\n\nexport function joinSplittedInput({ minusSign, integer, delimiter, fraction }: NumberFormatSplittedInput): string {\n\treturn `${minusSign}${integer}${delimiter}${fraction}`;\n}\n\nexport function canCastSplittedInputToNumber({ integer, fraction }: NumberFormatSplittedInput): boolean {\n\treturn integer !== '' || fraction !== '';\n}\n","import { isNil } from '@lucca-front/ng/core';\nimport { canCastSplittedInputToNumber, joinSplittedInput, NumberFormatOptions, NumberFormatParsedInput, NumberFormatSplittedInput } from './number-format.models';\n\nconst VALUE_TYPES: Intl.NumberFormatPartTypes[] = ['integer', 'decimal', 'fraction', 'group', 'minusSign'];\n\nconst DIGIT_TYPES: Intl.NumberFormatPartTypes[] = ['integer', 'decimal', 'fraction'];\n\nconst SUFFIX_PREFIX_TYPES: Intl.NumberFormatPartTypes[] = ['percent', 'percentSign', 'currency', 'unit'];\n\nexport class NumberFormat {\n\treadonly locale: string;\n\treadonly min: number | undefined;\n\treadonly max: number | undefined;\n\treadonly options: Intl.NumberFormatOptions;\n\treadonly #focusIntlNumberFormat: Intl.NumberFormat;\n\treadonly #intlNumberFormat: Intl.NumberFormat;\n\n\tconstructor({ locale, min, max, ...options }: NumberFormatOptions) {\n\t\tthis.locale = locale;\n\t\tthis.min = min;\n\t\tthis.max = max;\n\t\tthis.options = this.#applyBoundariesToDigitOptions(options);\n\t\tthis.#intlNumberFormat = new Intl.NumberFormat(this.locale, this.options);\n\t\tthis.#focusIntlNumberFormat = new Intl.NumberFormat(this.locale, {\n\t\t\t...this.options,\n\t\t\tminimumFractionDigits: 0,\n\t\t});\n\t}\n\n\t#applyBoundariesToDigitOptions({\n\t\tstyle,\n\t\tminimumFractionDigits,\n\t\tmaximumFractionDigits,\n\t\tminimumIntegerDigits,\n\t\tminimumSignificantDigits,\n\t\tmaximumSignificantDigits,\n\t\t...options\n\t}: Intl.NumberFormatOptions): Intl.NumberFormatOptions {\n\t\tstyle = style ?? 'decimal';\n\t\tif (style !== 'currency') {\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#minimumfractiondigits\n\t\t\tminimumFractionDigits = Math.min(Math.max(minimumFractionDigits ?? 0, 0), 20);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumfractiondigits\n\t\t\tmaximumFractionDigits = Math.min(Math.max(maximumFractionDigits ?? 2, minimumFractionDigits), 20);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumfractiondigits\n\t\t\tminimumIntegerDigits = Math.min(Math.max(minimumFractionDigits ?? 1, 1), 21);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#minimumsignificantdigits\n\t\t\tminimumSignificantDigits = Math.min(Math.max(minimumSignificantDigits ?? 1, 1), 21);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumsignificantdigits\n\t\t\tmaximumSignificantDigits = Math.min(Math.max(maximumSignificantDigits ?? 21, minimumSignificantDigits), 21);\n\t\t}\n\t\treturn {\n\t\t\t...options,\n\t\t\tstyle,\n\t\t\tminimumFractionDigits,\n\t\t\tmaximumFractionDigits,\n\t\t\tminimumIntegerDigits,\n\t\t\tminimumSignificantDigits,\n\t\t\tmaximumSignificantDigits,\n\t\t};\n\t}\n\n\tgetSuffix(value: number | null): string | null {\n\t\tvalue = value ?? 1;\n\n\t\t// Parts after digits are suffix\n\t\tconst parts = this.#intlNumberFormat.formatToParts(value).reverse();\n\t\tconst indexOfFirstDigit = parts.findIndex((p) => DIGIT_TYPES.includes(p.type));\n\t\tconst indexOfFirstSuffix = parts.findIndex((p) => SUFFIX_PREFIX_TYPES.includes(p.type));\n\t\tif (indexOfFirstSuffix >= 0 && indexOfFirstSuffix < indexOfFirstDigit) {\n\t\t\treturn parts[indexOfFirstSuffix].value;\n\t\t}\n\t\treturn null;\n\t}\n\n\tgetPrefix(value: number | null): string | null {\n\t\tvalue = value ?? 1;\n\n\t\t// Parts before digits are prefix\n\t\tconst parts = this.#intlNumberFormat.formatToParts(value);\n\t\tconst indexOfLastDigit = parts.findIndex((p) => DIGIT_TYPES.includes(p.type));\n\t\tconst indexOfLastSuffix = parts.findIndex((p) => SUFFIX_PREFIX_TYPES.includes(p.type));\n\t\tif (indexOfLastSuffix >= 0 && indexOfLastSuffix < indexOfLastDigit) {\n\t\t\treturn parts[indexOfLastSuffix].value;\n\t\t}\n\t\treturn null;\n\t}\n\n\tapplyRange(value: number | null | undefined): number | null {\n\t\tif (isNil(value)) {\n\t\t\treturn null;\n\t\t}\n\t\tif (this.min !== undefined) {\n\t\t\tvalue = Math.max(this.min, value);\n\t\t}\n\t\tif (this.max !== undefined) {\n\t\t\tvalue = Math.min(this.max, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\t#parseAndSplitInput(input: string): NumberFormatSplittedInput {\n\t\tlet minusSign = /^-/g.exec(input)?.[0] ?? '';\n\t\t// if minus sign has been input but range only allows positive values, remove it\n\t\tif (this.min !== undefined && this.min >= 0) {\n\t\t\tminusSign = '';\n\t\t}\n\n\t\t// Add minus sign by default if range only allows negative values\n\t\tif (this.max !== undefined && this.max < 0) {\n\t\t\tminusSign = '-';\n\t\t}\n\n\t\t// Keep only digits and decimal delimiter\n\t\tinput = input.replace(/[^.,0-9]/g, '');\n\n\t\t// Replace decimal delimiter ',' by '.' before casting string to number\n\t\tinput = input.replace(/,/g, '.');\n\n\t\tconst parts = input.split('.');\n\t\tconst integer = parts[0];\n\t\tconst fraction = parts\n\t\t\t.slice(1)\n\t\t\t.join('')\n\t\t\t//ignore digits above maximumFractionDigits\n\t\t\t.slice(0, this.options.maximumFractionDigits ?? 2);\n\t\tconst delimiter = parts.length > 1 ? '.' : '';\n\n\t\tconst splittedInput: NumberFormatSplittedInput = {\n\t\t\tminusSign,\n\t\t\tinteger,\n\t\t\tdelimiter,\n\t\t\tfraction,\n\t\t};\n\n\t\t// cast input in number only if it has integer or fraction\n\t\tif (canCastSplittedInputToNumber(splittedInput)) {\n\t\t\tlet value = +joinSplittedInput(splittedInput);\n\t\t\tif (this.options.style === 'percent') {\n\t\t\t\tvalue /= 100;\n\t\t\t\tvalue = this.options.maximumFractionDigits ? +value.toFixed(this.options.maximumFractionDigits + 2) : value;\n\t\t\t}\n\n\t\t\t// if value is not in range, fix it and split again !\n\t\t\tconst valueInRange = this.applyRange(value);\n\t\t\tif (value !== valueInRange) {\n\t\t\t\treturn this.#parseAndSplitInput(this.getFocusFormat(valueInRange));\n\t\t\t}\n\t\t}\n\t\treturn splittedInput;\n\t}\n\n\tparse(input: string): NumberFormatParsedInput {\n\t\tconst splittedInput = this.#parseAndSplitInput(input);\n\t\tconst cleanInput = joinSplittedInput(splittedInput);\n\t\tlet value: number | null = null;\n\n\t\tif (canCastSplittedInputToNumber(splittedInput)) {\n\t\t\tvalue = +joinSplittedInput(splittedInput);\n\t\t\tif (this.options.style === 'percent') {\n\t\t\t\tvalue /= 100;\n\t\t\t\tvalue = this.options.maximumFractionDigits ? +value.toFixed(this.options.maximumFractionDigits + 2) : value;\n\t\t\t}\n\t\t}\n\t\treturn {\n\t\t\tsplittedInput,\n\t\t\tcleanInput,\n\t\t\tvalue,\n\t\t};\n\t}\n\n\tformat(value: number | null): string {\n\t\tif (value === null) {\n\t\t\treturn '';\n\t\t}\n\t\treturn this.#intlNumberFormat.format(value);\n\t}\n\n\tgetFocusFormat(value: number | undefined | null): string {\n\t\tif (isNil(value) || isNaN(value)) {\n\t\t\t// Add minus sign by default if range only allows negative values\n\t\t\treturn this.max !== undefined && this.max < 0 ? '-' : '';\n\t\t}\n\t\tconst parts = this.#focusIntlNumberFormat.formatToParts(value);\n\t\tconst minusSign = parts.find((p) => p.type === 'minusSign')?.value ?? '';\n\t\tconst integerPart = parts\n\t\t\t.filter((p) => p.type === 'integer')\n\t\t\t.map((p) => p.value)\n\t\t\t.join('');\n\t\tconst decimal = parts.find((p) => p.type === 'decimal') ? '.' : '';\n\t\tconst fractionPart = parts\n\t\t\t.filter((p) => p.type === 'fraction')\n\t\t\t.map((p) => p.value)\n\t\t\t.join('');\n\n\t\treturn `${minusSign}${integerPart}${decimal}${fractionPart}`;\n\t}\n\n\tgetBlurFormat(value: number | undefined | null): string {\n\t\tif (isNil(value)) {\n\t\t\treturn '';\n\t\t}\n\t\treturn this.#intlNumberFormat\n\t\t\t.formatToParts(value)\n\t\t\t.filter((p) => VALUE_TYPES.includes(p.type))\n\t\t\t.map((p) => {\n\t\t\t\tif (p.type === 'minusSign') {\n\t\t\t\t\treturn '−';\n\t\t\t\t}\n\t\t\t\treturn p.value;\n\t\t\t})\n\t\t\t.join('');\n\t}\n}\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { NumberFormat } from './number-format';\nimport { NumberFormatOptions } from './number-format.models';\n\n@Pipe({\n\tname: 'luNumberFormat',\n})\nexport class LuFormatNumberPipe implements PipeTransform {\n\ttransform(value: number, options: NumberFormatOptions) {\n\t\treturn new NumberFormat(options).format(value);\n\t}\n}\n","// Based on Intl number input\n// (more info: https://dm4t2.github.io/)\n\nimport { computed, Directive, ElementRef, forwardRef, inject, input, Renderer2, signal } from '@angular/core';\nimport type { ControlValueAccessor } from '@angular/forms';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { NumberFormat } from './number-format';\nimport { NumberFormatOptions } from './number-format.models';\n\n@Directive({\n\tselector: 'input[luNumberFormatInput]',\n\thost: {\n\t\t'(focus)': 'focus()',\n\t\t'(blur)': 'lostFocus()',\n\t\t'(input)': 'input()',\n\t},\n\tproviders: [\n\t\t{\n\t\t\tprovide: NG_VALUE_ACCESSOR,\n\t\t\tuseExisting: forwardRef(() => NumberFormatDirective),\n\t\t\tmulti: true,\n\t\t},\n\t],\n})\nexport class NumberFormatDirective implements ControlValueAccessor {\n\treadonly #inputElement = inject<ElementRef<HTMLInputElement>>(ElementRef<HTMLInputElement>).nativeElement;\n\treadonly #renderer = inject(Renderer2);\n\n\treadonly #value = signal<number | undefined | null>(null);\n\treadonly #isFocused = signal<boolean>(false);\n\n\treadonly formatOptions = input.required<NumberFormatOptions>();\n\treadonly #numberFormat = computed(() => {\n\t\treturn new NumberFormat(this.formatOptions());\n\t});\n\n\tonChange: (_value: number | undefined | null) => void = () => {};\n\n\tonTouched: () => void = (): void => {};\n\n\twriteValue(value: number | undefined | null): void {\n\t\tvalue = this.#numberFormat().applyRange(value);\n\t\tthis.#value.set(value);\n\t\tthis.#inputElement.value = this.#isFocused() ? this.#numberFormat().getFocusFormat(value) : this.#numberFormat().getBlurFormat(value);\n\t}\n\n\tregisterOnChange(fn: (_value: number | undefined | null) => void): void {\n\t\tthis.onChange = fn;\n\t}\n\n\tregisterOnTouched(fn: () => void): void {\n\t\tthis.onTouched = fn;\n\t}\n\n\tsetDisabledState(isDisabled: boolean): void {\n\t\tthis.#renderer.setProperty(this.#inputElement, 'disabled', isDisabled);\n\t}\n\tfocus(): void {\n\t\tthis.#isFocused.set(true);\n\t\tthis.#inputElement.value = this.#numberFormat().getFocusFormat(this.#value());\n\t}\n\n\tlostFocus(): void {\n\t\tthis.#isFocused.set(false);\n\t\tthis.#inputElement.value = this.#numberFormat().getBlurFormat(this.#value());\n\t\tthis.onTouched();\n\t}\n\n\tinput(): void {\n\t\tconst parsedInput = this.#numberFormat().parse(this.#inputElement.value);\n\n\t\tthis.#inputElement.value = parsedInput.cleanInput;\n\n\t\tthis.#value.set(parsedInput.value);\n\n\t\tthis.onChange?.(parsedInput.value);\n\t}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAmFM,SAAU,iBAAiB,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAA6B,EAAA;IACvG,OAAO,CAAA,EAAG,SAAS,CAAA,EAAG,OAAO,GAAG,SAAS,CAAA,EAAG,QAAQ,CAAA,CAAE;AACvD;SAEgB,4BAA4B,CAAC,EAAE,OAAO,EAAE,QAAQ,EAA6B,EAAA;AAC5F,IAAA,OAAO,OAAO,KAAK,EAAE,IAAI,QAAQ,KAAK,EAAE;AACzC;;ACtFA,MAAM,WAAW,GAAiC,CAAC,SAAS,EAAE,SAAS,EAAE,UAAU,EAAE,OAAO,EAAE,WAAW,CAAC;AAE1G,MAAM,WAAW,GAAiC,CAAC,SAAS,EAAE,SAAS,EAAE,UAAU,CAAC;AAEpF,MAAM,mBAAmB,GAAiC,CAAC,SAAS,EAAE,aAAa,EAAE,UAAU,EAAE,MAAM,CAAC;MAE3F,YAAY,CAAA;AAKf,IAAA,sBAAs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A,IAAA,EAAA,qBAAqB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,4BAAA,EAAA,MAAA,EAAA,EAAA,aAAA,EAAA,EAAA,iBAAA,EAAA,eAAA,EAAA,UAAA,EAAA,eAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,IAAA,EAAA,EAAA,SAAA,EAAA,EAAA,OAAA,EAAA,SAAA,EAAA,MAAA,EAAA,aAAA,EAAA,OAAA,EAAA,SAAA,EAAA,EAAA,EAAA,SAAA,EARtB;AACV,YAAA;AACC,gBAAA,OAAO,EAAE,iBAAiB;AAC1B,gBAAA,WAAW,EAAE,UAAU,CAAC,MAAM,qBAAqB,CAAC;AACpD,gBAAA,KAAK,EAAE,IAAI;AACX,aAAA;AACD,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;4FAEW,qBAAqB,EAAA,UAAA,EAAA,CAAA;kBAfjC,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACV,oBAAA,QAAQ,EAAE,4BAA4B;AACtC,oBAAA,IAAI,EAAE;AACL,wBAAA,SAAS,EAAE,SAAS;AACpB,wBAAA,QAAQ,EAAE,aAAa;AACvB,wBAAA,SAAS,EAAE,SAAS;AACpB,qBAAA;AACD,oBAAA,SAAS,EAAE;AACV,wBAAA;AACC,4BAAA,OAAO,EAAE,iBAAiB;AAC1B,4BAAA,WAAW,EAAE,UAAU,CAAC,2BAA2B,CAAC;AACpD,4BAAA,KAAK,EAAE,IAAI;AACX,yBAAA;AACD,qBAAA;AACD,iBAAA;;;ACvBD;;AAEG;;;;"}
1
+ {"version":3,"file":"lucca-front-ng-number-format.mjs","sources":["../../../packages/ng/number-format/number-format.models.ts","../../../packages/ng/number-format/number-format.ts","../../../packages/ng/number-format/number-format.pipe.ts","../../../packages/ng/number-format/number-format.directive.ts","../../../packages/ng/number-format/lucca-front-ng-number-format.ts"],"sourcesContent":["export type NumberFormatStyle = 'decimal' | 'currency' | 'percent' | 'unit';\n\nexport type NumberFormatUnit =\n\t| 'acre'\n\t| 'bit'\n\t| 'byte'\n\t| 'celsius'\n\t| 'centimeter'\n\t| 'day'\n\t| 'degree'\n\t| 'fahrenheit'\n\t| 'fluid-ounce'\n\t| 'foot'\n\t| 'gallon'\n\t| 'gigabit'\n\t| 'gigabyte'\n\t| 'gram'\n\t| 'hectare'\n\t| 'hour'\n\t| 'inch'\n\t| 'kilobit'\n\t| 'kilobyte'\n\t| 'kilogram'\n\t| 'kilometer'\n\t| 'liter'\n\t| 'megabit'\n\t| 'megabyte'\n\t| 'meter'\n\t| 'microsecond'\n\t| 'mile'\n\t| 'mile-scandinavian'\n\t| 'milliliter'\n\t| 'millimeter'\n\t| 'millisecond'\n\t| 'minute'\n\t| 'month'\n\t| 'nanosecond'\n\t| 'ounce'\n\t| 'percent'\n\t| 'petabyte'\n\t| 'pound'\n\t| 'second'\n\t| 'stone'\n\t| 'terabit'\n\t| 'terabyte'\n\t| 'week'\n\t| 'yard'\n\t| 'year';\n\nexport type NumberFormatUnitDisplay = 'short' | 'narrow' | 'long';\n\nexport type NumberFormatCurrencyDisplay = 'code' | 'symbol' | 'narrowSymbol' | 'name';\n\nexport interface NumberFormatOptions {\n\tlocale: string;\n\tmin?: number | undefined;\n\tmax?: number | undefined;\n\tstyle: NumberFormatStyle;\n\tcurrency?: string | undefined;\n\tcurrencyDisplay?: NumberFormatCurrencyDisplay | undefined;\n\tunit?: NumberFormatUnit | undefined;\n\tunitDisplay?: NumberFormatUnitDisplay | undefined;\n\tuseGrouping?: boolean | undefined;\n\tminimumIntegerDigits?: number | undefined;\n\tminimumFractionDigits?: number | undefined;\n\tmaximumFractionDigits?: number | undefined;\n\tminimumSignificantDigits?: number | undefined;\n\tmaximumSignificantDigits?: number | undefined;\n}\n\nexport interface NumberFormatSplittedInput {\n\tminusSign: string;\n\tinteger: string;\n\tdelimiter: string;\n\tfraction: string;\n}\n\nexport interface NumberFormatParsedInput {\n\tsplittedInput: NumberFormatSplittedInput;\n\tcleanInput: string;\n\tvalue: number | null;\n}\n\nexport function joinSplittedInput({ minusSign, integer, delimiter, fraction }: NumberFormatSplittedInput): string {\n\treturn `${minusSign}${integer}${delimiter}${fraction}`;\n}\n\nexport function canCastSplittedInputToNumber({ integer, fraction }: NumberFormatSplittedInput): boolean {\n\treturn integer !== '' || fraction !== '';\n}\n","import { isNil } from '@lucca-front/ng/core';\nimport { canCastSplittedInputToNumber, joinSplittedInput, NumberFormatOptions, NumberFormatParsedInput, NumberFormatSplittedInput } from './number-format.models';\n\nconst VALUE_TYPES: Intl.NumberFormatPartTypes[] = ['integer', 'decimal', 'fraction', 'group', 'minusSign'];\n\nconst DIGIT_TYPES: Intl.NumberFormatPartTypes[] = ['integer', 'decimal', 'fraction'];\n\nconst SUFFIX_PREFIX_TYPES: Intl.NumberFormatPartTypes[] = ['percent', 'percentSign', 'currency', 'unit'];\n\nexport class NumberFormat {\n\treadonly locale: string;\n\treadonly min: number | undefined;\n\treadonly max: number | undefined;\n\treadonly options: Intl.NumberFormatOptions;\n\treadonly #focusIntlNumberFormat: Intl.NumberFormat;\n\treadonly #intlNumberFormat: Intl.NumberFormat;\n\n\tconstructor({ locale, min, max, ...options }: NumberFormatOptions) {\n\t\tthis.locale = locale;\n\t\tthis.min = min;\n\t\tthis.max = max;\n\t\tthis.options = this.#applyBoundariesToDigitOptions(options);\n\t\tthis.#intlNumberFormat = new Intl.NumberFormat(this.locale, this.options);\n\t\tthis.#focusIntlNumberFormat = new Intl.NumberFormat(this.locale, {\n\t\t\t...this.options,\n\t\t\tminimumFractionDigits: 0,\n\t\t});\n\t}\n\n\t#applyBoundariesToDigitOptions({\n\t\tstyle,\n\t\tminimumFractionDigits,\n\t\tmaximumFractionDigits,\n\t\tminimumIntegerDigits,\n\t\tminimumSignificantDigits,\n\t\tmaximumSignificantDigits,\n\t\t...options\n\t}: Intl.NumberFormatOptions): Intl.NumberFormatOptions {\n\t\tstyle = style ?? 'decimal';\n\t\tif (style !== 'currency') {\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#minimumfractiondigits\n\t\t\tminimumFractionDigits = Math.min(Math.max(minimumFractionDigits ?? 0, 0), 20);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumfractiondigits\n\t\t\tmaximumFractionDigits = Math.min(Math.max(maximumFractionDigits ?? 2, minimumFractionDigits), 20);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumfractiondigits\n\t\t\tminimumIntegerDigits = Math.min(Math.max(minimumFractionDigits ?? 1, 1), 21);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#minimumsignificantdigits\n\t\t\tminimumSignificantDigits = Math.min(Math.max(minimumSignificantDigits ?? 1, 1), 21);\n\t\t\t// https://developer.mozilla.org/fr/docs/Web/JavaScript/Reference/Global_Objects/Intl/NumberFormat/NumberFormat#maximumsignificantdigits\n\t\t\tmaximumSignificantDigits = Math.min(Math.max(maximumSignificantDigits ?? 21, minimumSignificantDigits), 21);\n\t\t}\n\t\treturn {\n\t\t\t...options,\n\t\t\tstyle,\n\t\t\tminimumFractionDigits,\n\t\t\tmaximumFractionDigits,\n\t\t\tminimumIntegerDigits,\n\t\t\tminimumSignificantDigits,\n\t\t\tmaximumSignificantDigits,\n\t\t};\n\t}\n\n\tgetSuffix(value: number | null): string | null {\n\t\tvalue = value ?? 1;\n\n\t\t// Parts after digits are suffix\n\t\tconst parts = this.#intlNumberFormat.formatToParts(value).reverse();\n\t\tconst indexOfFirstDigit = parts.findIndex((p) => DIGIT_TYPES.includes(p.type));\n\t\tconst indexOfFirstSuffix = parts.findIndex((p) => SUFFIX_PREFIX_TYPES.includes(p.type));\n\t\tif (indexOfFirstSuffix >= 0 && indexOfFirstSuffix < indexOfFirstDigit) {\n\t\t\treturn parts[indexOfFirstSuffix].value;\n\t\t}\n\t\treturn null;\n\t}\n\n\tgetPrefix(value: number | null): string | null {\n\t\tvalue = value ?? 1;\n\n\t\t// Parts before digits are prefix\n\t\tconst parts = this.#intlNumberFormat.formatToParts(value);\n\t\tconst indexOfLastDigit = parts.findIndex((p) => DIGIT_TYPES.includes(p.type));\n\t\tconst indexOfLastSuffix = parts.findIndex((p) => SUFFIX_PREFIX_TYPES.includes(p.type));\n\t\tif (indexOfLastSuffix >= 0 && indexOfLastSuffix < indexOfLastDigit) {\n\t\t\treturn parts[indexOfLastSuffix].value;\n\t\t}\n\t\treturn null;\n\t}\n\n\tapplyRange(value: number | null | undefined): number | null {\n\t\tif (isNil(value)) {\n\t\t\treturn null;\n\t\t}\n\t\tif (this.min !== undefined) {\n\t\t\tvalue = Math.max(this.min, value);\n\t\t}\n\t\tif (this.max !== undefined) {\n\t\t\tvalue = Math.min(this.max, value);\n\t\t}\n\t\treturn value;\n\t}\n\n\t#parseAndSplitInput(input: string): NumberFormatSplittedInput {\n\t\tlet minusSign = /^-/g.exec(input)?.[0] ?? '';\n\t\t// if minus sign has been input but range only allows positive values, remove it\n\t\tif (this.min !== undefined && this.min >= 0) {\n\t\t\tminusSign = '';\n\t\t}\n\n\t\t// Add minus sign by default if range only allows negative values\n\t\tif (this.max !== undefined && this.max < 0) {\n\t\t\tminusSign = '-';\n\t\t}\n\n\t\t// Keep only digits and decimal delimiter\n\t\tinput = input.replace(/[^.,0-9]/g, '');\n\n\t\t// Replace decimal delimiter ',' by '.' before casting string to number\n\t\tinput = input.replace(/,/g, '.');\n\n\t\tconst parts = input.split('.');\n\t\tconst integer = parts[0];\n\t\tconst fraction = parts\n\t\t\t.slice(1)\n\t\t\t.join('')\n\t\t\t//ignore digits above maximumFractionDigits\n\t\t\t.slice(0, this.options.maximumFractionDigits ?? 2);\n\t\tconst delimiter = parts.length > 1 ? '.' : '';\n\n\t\tconst splittedInput: NumberFormatSplittedInput = {\n\t\t\tminusSign,\n\t\t\tinteger,\n\t\t\tdelimiter,\n\t\t\tfraction,\n\t\t};\n\n\t\t// cast input in number only if it has integer or fraction\n\t\tif (canCastSplittedInputToNumber(splittedInput)) {\n\t\t\tlet value = +joinSplittedInput(splittedInput);\n\t\t\tif (this.options.style === 'percent') {\n\t\t\t\tvalue /= 100;\n\t\t\t\tvalue = this.options.maximumFractionDigits ? +value.toFixed(this.options.maximumFractionDigits + 2) : value;\n\t\t\t}\n\n\t\t\t// if value is not in range, fix it and split again !\n\t\t\tconst valueInRange = this.applyRange(value);\n\t\t\tif (value !== valueInRange) {\n\t\t\t\treturn this.#parseAndSplitInput(this.getFocusFormat(valueInRange));\n\t\t\t}\n\t\t}\n\t\treturn splittedInput;\n\t}\n\n\tparse(input: string): NumberFormatParsedInput {\n\t\tconst splittedInput = this.#parseAndSplitInput(input);\n\t\tconst cleanInput = joinSplittedInput(splittedInput);\n\t\tlet value: number | null = null;\n\n\t\tif (canCastSplittedInputToNumber(splittedInput)) {\n\t\t\tvalue = +joinSplittedInput(splittedInput);\n\t\t\tif (this.options.style === 'percent') {\n\t\t\t\tvalue /= 100;\n\t\t\t\tvalue = this.options.maximumFractionDigits ? +value.toFixed(this.options.maximumFractionDigits + 2) : value;\n\t\t\t}\n\t\t}\n\t\treturn {\n\t\t\tsplittedInput,\n\t\t\tcleanInput,\n\t\t\tvalue,\n\t\t};\n\t}\n\n\tformat(value: number | null): string {\n\t\tif (value === null) {\n\t\t\treturn '';\n\t\t}\n\t\treturn this.#intlNumberFormat.format(value);\n\t}\n\n\tgetFocusFormat(value: number | undefined | null): string {\n\t\tif (isNil(value) || isNaN(value)) {\n\t\t\t// Add minus sign by default if range only allows negative values\n\t\t\treturn this.max !== undefined && this.max < 0 ? '-' : '';\n\t\t}\n\t\tconst parts = this.#focusIntlNumberFormat.formatToParts(value);\n\t\tconst minusSign = parts.find((p) => p.type === 'minusSign')?.value ?? '';\n\t\tconst integerPart = parts\n\t\t\t.filter((p) => p.type === 'integer')\n\t\t\t.map((p) => p.value)\n\t\t\t.join('');\n\t\tconst decimal = parts.find((p) => p.type === 'decimal') ? '.' : '';\n\t\tconst fractionPart = parts\n\t\t\t.filter((p) => p.type === 'fraction')\n\t\t\t.map((p) => p.value)\n\t\t\t.join('');\n\n\t\treturn `${minusSign}${integerPart}${decimal}${fractionPart}`;\n\t}\n\n\tgetBlurFormat(value: number | undefined | null): string {\n\t\tif (isNil(value)) {\n\t\t\treturn '';\n\t\t}\n\t\treturn this.#intlNumberFormat\n\t\t\t.formatToParts(value)\n\t\t\t.filter((p) => VALUE_TYPES.includes(p.type))\n\t\t\t.map((p) => {\n\t\t\t\tif (p.type === 'minusSign') {\n\t\t\t\t\treturn '−';\n\t\t\t\t}\n\t\t\t\treturn p.value;\n\t\t\t})\n\t\t\t.join('');\n\t}\n}\n","import { Pipe, PipeTransform } from '@angular/core';\nimport { NumberFormat } from './number-format';\nimport { NumberFormatOptions } from './number-format.models';\n\n@Pipe({\n\tname: 'luNumberFormat',\n})\nexport class LuFormatNumberPipe implements PipeTransform {\n\ttransform(value: number, options: NumberFormatOptions) {\n\t\treturn new NumberFormat(options).format(value);\n\t}\n}\n","// Based on Intl number input\n// (more info: https://dm4t2.github.io/)\n\nimport { computed, Directive, ElementRef, forwardRef, HostListener, inject, input, Renderer2, signal } from '@angular/core';\nimport type { ControlValueAccessor } from '@angular/forms';\nimport { NG_VALUE_ACCESSOR } from '@angular/forms';\nimport { NumberFormat } from './number-format';\nimport { NumberFormatOptions } from './number-format.models';\n\n@Directive({\n\tselector: 'input[luNumberFormatInput]',\n\tproviders: [\n\t\t{\n\t\t\tprovide: NG_VALUE_ACCESSOR,\n\t\t\tuseExisting: forwardRef(() => NumberFormatDirective),\n\t\t\tmulti: true,\n\t\t},\n\t],\n})\nexport class NumberFormatDirective implements ControlValueAccessor {\n\treadonly #inputElement = inject<ElementRef<HTMLInputElement>>(ElementRef<HTMLInputElement>).nativeElement;\n\treadonly #renderer = inject(Renderer2);\n\n\treadonly #value = signal<number | undefined | null>(null);\n\treadonly #isFocused = signal<boolean>(false);\n\n\treadonly formatOptions = input.required<NumberFormatOptions>();\n\treadonly #numberFormat = computed(() => {\n\t\treturn new NumberFormat(this.formatOptions());\n\t});\n\n\tonChange: (_value: number | undefined | null) => void = () => {};\n\n\tonTouched: () => void = (): void => {};\n\n\twriteValue(value: number | undefined | null): void {\n\t\tvalue = this.#numberFormat().applyRange(value);\n\t\tthis.#value.set(value);\n\t\tthis.#inputElement.value = this.#isFocused() ? this.#numberFormat().getFocusFormat(value) : this.#numberFormat().getBlurFormat(value);\n\t}\n\n\tregisterOnChange(fn: (_value: number | undefined | null) => void): void {\n\t\tthis.onChange = fn;\n\t}\n\n\tregisterOnTouched(fn: () => void): void {\n\t\tthis.onTouched = fn;\n\t}\n\n\tsetDisabledState(isDisabled: boolean): void {\n\t\tthis.#renderer.setProperty(this.#inputElement, 'disabled', isDisabled);\n\t}\n\t@HostListener('focus') focus(): void {\n\t\tthis.#isFocused.set(true);\n\t\tthis.#inputElement.value = this.#numberFormat().getFocusFormat(this.#value());\n\t}\n\n\t@HostListener('blur') lostFocus(): void {\n\t\tthis.#isFocused.set(false);\n\t\tthis.#inputElement.value = this.#numberFormat().getBlurFormat(this.#value());\n\t\tthis.onTouched();\n\t}\n\n\t@HostListener('input') input(): void {\n\t\tconst parsedInput = this.#numberFormat().parse(this.#inputElement.value);\n\n\t\tthis.#inputElement.value = parsedInput.cleanInput;\n\n\t\tthis.#value.set(parsedInput.value);\n\n\t\tthis.onChange?.(parsedInput.value);\n\t}\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAmFM,SAAU,iBAAiB,CAAC,EAAE,SAAS,EAAE,OAAO,EAAE,SAAS,EAAE,QAAQ,EAA6B,EAAA;IACvG,OAAO,CAAA,EAAG,SAAS,CAAA,EAAG,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E,iBAAiB;AAC1B,4BAAA,WAAW,EAAE,UAAU,CAAC,2BAA2B,CAAC;AACpD,4BAAA,KAAK,EAAE,IAAI;AACX,yBAAA;AACD,qBAAA;AACD,iBAAA;;sBAkCC,YAAY;uBAAC,OAAO;;sBAKpB,YAAY;uBAAC,MAAM;;sBAMnB,YAAY;uBAAC,OAAO;;;AC/DtB;;AAEG;;;;"}
@@ -1,6 +1,6 @@
1
1
  import * as i0 from '@angular/core';
2
- import { EventEmitter, ElementRef, forwardRef, ViewChild, Input, Output, ChangeDetectionStrategy, Component, NgModule, InjectionToken, input, ViewContainerRef, ContentChild, Directive, viewChild, HostBinding, inject, DestroyRef, TemplateRef, ContentChildren, Inject } from '@angular/core';
3
- import { intlInputOptions, syncInputSignal, ALuOnScrollBottomSubscriber, ALuOnOpenSubscriber, ALuOnCloseSubscriber } from '@lucca-front/ng/core';
2
+ import { EventEmitter, ElementRef, forwardRef, ViewChild, Input, Output, ChangeDetectionStrategy, Component, NgModule, InjectionToken, input, ViewContainerRef, ContentChild, Directive, HostBinding, inject, DestroyRef, TemplateRef, ContentChildren, Inject } from '@angular/core';
3
+ import { intlInputOptions, ALuOnScrollBottomSubscriber, ALuOnOpenSubscriber, ALuOnCloseSubscriber } from '@lucca-front/ng/core';
4
4
  import { ALuInputDisplayer } from '@lucca-front/ng/input';
5
5
  import { LuTooltipTriggerDirective } from '@lucca-front/ng/tooltip';
6
6
  import * as i1$1 from '@angular/cdk/a11y';
@@ -12,15 +12,14 @@ import { luTransformPopover } from '@lucca-front/ng/popover';
12
12
  import { LuScrollDirective } from '@lucca-front/ng/scroll';
13
13
  import { BehaviorSubject, Subscription, combineLatest, merge, of, Subject } from 'rxjs';
14
14
  import { map, tap, switchMap, delay, share, first, startWith, shareReplay, mergeAll } from 'rxjs/operators';
15
- import { toObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
16
15
  import * as i1 from '@angular/forms';
17
16
  import { FormControl, ReactiveFormsModule } from '@angular/forms';
17
+ import { takeUntilDestroyed } from '@angular/core/rxjs-interop';
18
18
 
19
19
  class ALuOptionItem {
20
20
  }
21
21
 
22
22
  /* eslint-disable @angular-eslint/no-output-on-prefix */
23
- /* eslint-disable @angular-eslint/prefer-signals */
24
23
  /**
25
24
  * @deprecated
26
25
  */
@@ -157,7 +156,6 @@ const LU_TREE_OPTION_ITEM_TRANSLATIONS = new InjectionToken('LuTreeOptionItemTra
157
156
  });
158
157
  const luTreeOptionItemTranslations = Translations$2;
159
158
 
160
- /* eslint-disable @angular-eslint/prefer-signals */
161
159
  /**
162
160
  * @deprecated
163
161
  */
@@ -311,11 +309,13 @@ class ALuOptionOperator {
311
309
 
312
310
  class LuOptionFeederComponent {
313
311
  constructor() {
314
- this.options = input([], ...(ngDevMode ? [{ debugName: "options" }] : /* istanbul ignore next */ []));
315
- this.outOptions$ = toObservable(this.options);
312
+ this.outOptions$ = new BehaviorSubject([]);
313
+ }
314
+ set options(options) {
315
+ this.outOptions$.next(options);
316
316
  }
317
317
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: LuOptionFeederComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
318
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.14", type: LuOptionFeederComponent, isStandalone: true, selector: "lu-option-feeder", inputs: { options: { classPropertyName: "options", publicName: "options", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
318
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.14", type: LuOptionFeederComponent, isStandalone: true, selector: "lu-option-feeder", inputs: { options: "options" }, providers: [
319
319
  {
320
320
  provide: ALuOptionOperator,
321
321
  useExisting: forwardRef(() => LuOptionFeederComponent),
@@ -337,7 +337,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
337
337
  },
338
338
  ],
339
339
  }]
340
- }], propDecorators: { options: [{ type: i0.Input, args: [{ isSignal: true, alias: "options", required: false }] }] } });
340
+ }], propDecorators: { options: [{
341
+ type: Input
342
+ }] } });
341
343
 
342
344
  /**
343
345
  * @deprecated use `LuOptionFeederComponent` instead
@@ -358,7 +360,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
358
360
  class ALuTreeOptionOperator extends ALuOptionOperator {
359
361
  }
360
362
 
361
- /* eslint-disable @angular-eslint/prefer-signals */
362
363
  /**
363
364
  * @deprecated
364
365
  */
@@ -432,6 +433,9 @@ class LuForGroupContext {
432
433
  }
433
434
  }
434
435
  class LuForGroupsDirective {
436
+ set attrGroupBy(fn) {
437
+ this._groupByFn = fn;
438
+ }
435
439
  set inOptions$(options$) {
436
440
  this._subs.add(options$.subscribe((options) => this.render(options)));
437
441
  this.outOptions$ = options$;
@@ -440,9 +444,7 @@ class LuForGroupsDirective {
440
444
  this._vcr = _vcr;
441
445
  this._cdr = _cdr;
442
446
  this._templateRef = _templateRef;
443
- this.attrGroupBy = input(undefined, { ...(ngDevMode ? { debugName: "attrGroupBy" } : /* istanbul ignore next */ {}), alias: 'luForGroupsGroupBy' });
444
447
  this._subs = new Subscription();
445
- syncInputSignal(this.attrGroupBy, (fn) => (this._groupByFn = fn));
446
448
  }
447
449
  ngOnDestroy() {
448
450
  this._subs.unsubscribe();
@@ -470,7 +472,7 @@ class LuForGroupsDirective {
470
472
  return groups;
471
473
  }
472
474
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: LuForGroupsDirective, deps: [{ token: i0.ViewContainerRef }, { token: i0.ChangeDetectorRef }, { token: i0.TemplateRef }], target: i0.ɵɵFactoryTarget.Directive }); }
473
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.14", type: LuForGroupsDirective, isStandalone: true, selector: "[luForGroups]", inputs: { attrGroupBy: { classPropertyName: "attrGroupBy", publicName: "luForGroupsGroupBy", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
475
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.14", type: LuForGroupsDirective, isStandalone: true, selector: "[luForGroups]", inputs: { attrGroupBy: ["luForGroupsGroupBy", "attrGroupBy"] }, providers: [
474
476
  {
475
477
  provide: ALuOptionOperator,
476
478
  useExisting: forwardRef(() => LuForGroupsDirective),
@@ -490,7 +492,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
490
492
  },
491
493
  ],
492
494
  }]
493
- }], ctorParameters: () => [{ type: i0.ViewContainerRef }, { type: i0.ChangeDetectorRef }, { type: i0.TemplateRef }], propDecorators: { attrGroupBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "luForGroupsGroupBy", required: false }] }] } });
495
+ }], ctorParameters: () => [{ type: i0.ViewContainerRef }, { type: i0.ChangeDetectorRef }, { type: i0.TemplateRef }], propDecorators: { attrGroupBy: [{
496
+ type: Input,
497
+ args: ['luForGroupsGroupBy']
498
+ }] } });
494
499
 
495
500
  class LuForOptionsDirective extends NgForOf {
496
501
  set inOptions$(options$) {
@@ -500,18 +505,19 @@ class LuForOptionsDirective extends NgForOf {
500
505
  }));
501
506
  this.outOptions$ = options$;
502
507
  }
508
+ set luForOptionsTrackBy(fn) {
509
+ this.ngForTrackBy = fn;
510
+ }
503
511
  constructor(_viewContainer, _template, _differs, _changeDetectionRef) {
504
512
  super(_viewContainer, _template, _differs);
505
513
  this._changeDetectionRef = _changeDetectionRef;
506
514
  this._subs = new Subscription();
507
- this.luForOptionsTrackBy = input(...(ngDevMode ? [undefined, { debugName: "luForOptionsTrackBy" }] : /* istanbul ignore next */ []));
508
- syncInputSignal(this.luForOptionsTrackBy, (fn) => (this.ngForTrackBy = fn));
509
515
  }
510
516
  ngOnDestroy() {
511
517
  this._subs.unsubscribe();
512
518
  }
513
519
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: LuForOptionsDirective, deps: [{ token: i0.ViewContainerRef }, { token: i0.TemplateRef }, { token: i0.IterableDiffers }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Directive }); }
514
- static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "21.2.14", type: LuForOptionsDirective, isStandalone: true, selector: "[luForOptions]", inputs: { luForOptionsTrackBy: { classPropertyName: "luForOptionsTrackBy", publicName: "luForOptionsTrackBy", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
520
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "14.0.0", version: "21.2.14", type: LuForOptionsDirective, isStandalone: true, selector: "[luForOptions]", inputs: { luForOptionsTrackBy: "luForOptionsTrackBy" }, providers: [
515
521
  {
516
522
  provide: ALuOptionOperator,
517
523
  useExisting: forwardRef(() => LuForOptionsDirective),
@@ -531,7 +537,9 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
531
537
  },
532
538
  ],
533
539
  }]
534
- }], ctorParameters: () => [{ type: i0.ViewContainerRef }, { type: i0.TemplateRef }, { type: i0.IterableDiffers }, { type: i0.ChangeDetectorRef }], propDecorators: { luForOptionsTrackBy: [{ type: i0.Input, args: [{ isSignal: true, alias: "luForOptionsTrackBy", required: false }] }] } });
540
+ }], ctorParameters: () => [{ type: i0.ViewContainerRef }, { type: i0.TemplateRef }, { type: i0.IterableDiffers }, { type: i0.ChangeDetectorRef }], propDecorators: { luForOptionsTrackBy: [{
541
+ type: Input
542
+ }] } });
535
543
 
536
544
  /**
537
545
  * @deprecated use `LuForOptionsDirective` instead
@@ -800,24 +808,23 @@ class LuOptionSearcherComponent extends ALuOptionOperator {
800
808
  super(...arguments);
801
809
  this.searchControl = new FormControl();
802
810
  this.clue$ = merge(of(''), this.searchControl.valueChanges);
803
- this.searchInput = viewChild.required('searchInput');
804
- this.searchFn = input(() => true, ...(ngDevMode ? [{ debugName: "searchFn" }] : /* istanbul ignore next */ []));
811
+ this.searchFn = () => true;
805
812
  }
806
813
  set inOptions$(in$) {
807
814
  this.outOptions$ = combineLatest([in$, this.clue$]).pipe(map(([options, clue]) => {
808
- return clue ? (options || []).filter((o) => this.searchFn()(o, clue)) : options || [];
815
+ return clue ? (options || []).filter((o) => this.searchFn(o, clue)) : options || [];
809
816
  }));
810
817
  this.empty$ = this.outOptions$.pipe(map((o) => !o || o.length === 0));
811
818
  }
812
819
  onOpen() {
813
- this.searchInput().nativeElement.focus();
820
+ this.searchInput.nativeElement.focus();
814
821
  this.searchControl.setValue('');
815
822
  }
816
823
  resetClue() {
817
824
  this.searchControl.setValue('');
818
825
  }
819
826
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: LuOptionSearcherComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
820
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.14", type: LuOptionSearcherComponent, isStandalone: true, selector: "lu-option-searcher", inputs: { searchFn: { classPropertyName: "searchFn", publicName: "searchFn", isSignal: true, isRequired: false, transformFunction: null } }, providers: [
827
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.14", type: LuOptionSearcherComponent, isStandalone: true, selector: "lu-option-searcher", inputs: { searchFn: "searchFn" }, providers: [
821
828
  {
822
829
  provide: ALuOptionOperator,
823
830
  useExisting: forwardRef(() => LuOptionSearcherComponent),
@@ -828,7 +835,7 @@ class LuOptionSearcherComponent extends ALuOptionOperator {
828
835
  useExisting: forwardRef(() => LuOptionSearcherComponent),
829
836
  multi: true,
830
837
  },
831
- ], viewQueries: [{ propertyName: "searchInput", first: true, predicate: ["searchInput"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"textfield mod-search\">\n\t<input #searchInput class=\"textfield-input\" [formControl]=\"searchControl\" />\n</div>\n\n@if (empty$ | async) {\n\t<lu-option-placeholder (onClear)=\"resetClue()\" />\n}\n", styles: ["@layer base{:root{--components-options-item-padding-vertical: var(--pr-t-spacings-50);--components-options-item-padding-horizontal: var(--pr-t-spacings-100);--components-options-item-multiple-padding: 2.25rem;--components-options-item-icon-color: var(--palettes-neutral-800);--components-options-checkbox-size: 1.25rem;--components-options-checkbox-color: var(--palettes-700, var(--palettes-product-700));--components-options-checkbox-border-radius: var(--pr-t-border-radius-small);--components-options-checkbox-border-color: var(--palettes-neutral-700);--components-options-establishment-multiple-padding: 2rem}}@layer reset,base,components,mods,product,utils;@layer mods{.textfield.mod-search{inline-size:100%}.textfield-input{outline:none}.checkbox.mod-formerEmployee{padding-block:var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-horizontal);border-block-end:var(--commons-divider-width) solid var(--commons-divider-color);background-color:var(--palettes-neutral-50);font-style:italic}}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: LuOptionPlaceholderComponent, selector: "lu-option-placeholder", inputs: ["intl"], outputs: ["onClear"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
838
+ ], viewQueries: [{ propertyName: "searchInput", first: true, predicate: ["searchInput"], descendants: true, read: ElementRef, static: true }], usesInheritance: true, ngImport: i0, template: "<div class=\"textfield mod-search\">\n\t<input #searchInput class=\"textfield-input\" [formControl]=\"searchControl\" />\n</div>\n\n@if (empty$ | async) {\n\t<lu-option-placeholder (onClear)=\"resetClue()\" />\n}\n", styles: ["@layer base{:root{--components-options-item-padding-vertical: var(--pr-t-spacings-50);--components-options-item-padding-horizontal: var(--pr-t-spacings-100);--components-options-item-multiple-padding: 2.25rem;--components-options-item-icon-color: var(--palettes-neutral-800);--components-options-checkbox-size: 1.25rem;--components-options-checkbox-color: var(--palettes-700, var(--palettes-product-700));--components-options-checkbox-border-radius: var(--pr-t-border-radius-small);--components-options-checkbox-border-color: var(--palettes-neutral-700);--components-options-establishment-multiple-padding: 2rem}}@layer reset,base,components,mods,product,utils;@layer mods{.textfield.mod-search{inline-size:100%}.textfield-input{outline:none}.checkbox.mod-formerEmployee{padding-block:var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-horizontal);border-block-end:var(--commons-divider-width) solid var(--commons-divider-color);background-color:var(--palettes-neutral-50);font-style:italic}}\n"], dependencies: [{ kind: "ngmodule", type: ReactiveFormsModule }, { kind: "directive", type: i1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { kind: "directive", type: i1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { kind: "directive", type: i1.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { kind: "component", type: LuOptionPlaceholderComponent, selector: "lu-option-placeholder", inputs: ["intl"], outputs: ["onClear"] }, { kind: "pipe", type: AsyncPipe, name: "async" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
832
839
  }
833
840
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImport: i0, type: LuOptionSearcherComponent, decorators: [{
834
841
  type: Component,
@@ -844,7 +851,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
844
851
  multi: true,
845
852
  },
846
853
  ], template: "<div class=\"textfield mod-search\">\n\t<input #searchInput class=\"textfield-input\" [formControl]=\"searchControl\" />\n</div>\n\n@if (empty$ | async) {\n\t<lu-option-placeholder (onClear)=\"resetClue()\" />\n}\n", styles: ["@layer base{:root{--components-options-item-padding-vertical: var(--pr-t-spacings-50);--components-options-item-padding-horizontal: var(--pr-t-spacings-100);--components-options-item-multiple-padding: 2.25rem;--components-options-item-icon-color: var(--palettes-neutral-800);--components-options-checkbox-size: 1.25rem;--components-options-checkbox-color: var(--palettes-700, var(--palettes-product-700));--components-options-checkbox-border-radius: var(--pr-t-border-radius-small);--components-options-checkbox-border-color: var(--palettes-neutral-700);--components-options-establishment-multiple-padding: 2rem}}@layer reset,base,components,mods,product,utils;@layer mods{.textfield.mod-search{inline-size:100%}.textfield-input{outline:none}.checkbox.mod-formerEmployee{padding-block:var(--pr-t-spacings-50);padding-inline:var(--components-options-item-padding-horizontal);border-block-end:var(--commons-divider-width) solid var(--commons-divider-color);background-color:var(--palettes-neutral-50);font-style:italic}}\n"] }]
847
- }], propDecorators: { searchInput: [{ type: i0.ViewChild, args: ['searchInput', { isSignal: true }] }], searchFn: [{ type: i0.Input, args: [{ isSignal: true, alias: "searchFn", required: false }] }] } });
854
+ }], propDecorators: { searchInput: [{
855
+ type: ViewChild,
856
+ args: ['searchInput', { read: ElementRef, static: true }]
857
+ }], searchFn: [{
858
+ type: Input
859
+ }] } });
848
860
 
849
861
  /**
850
862
  * @deprecated use `LuOptionSearcherComponent` instead
@@ -862,7 +874,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
862
874
  }]
863
875
  }] });
864
876
 
865
- /* eslint-disable @angular-eslint/prefer-signals */
866
877
  /**
867
878
  * @deprecated
868
879
  */
@@ -1220,7 +1231,6 @@ class ALuOptionPicker extends ALuPickerPanel {
1220
1231
  }
1221
1232
 
1222
1233
  /* eslint-disable @angular-eslint/no-output-native */
1223
- /* eslint-disable @angular-eslint/prefer-signals */
1224
1234
  /**
1225
1235
  * @deprecated
1226
1236
  */
@@ -1528,7 +1538,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
1528
1538
  args: [DOCUMENT]
1529
1539
  }] }] });
1530
1540
 
1531
- /* eslint-disable @angular-eslint/prefer-signals */
1532
1541
  /**
1533
1542
  * @deprecated
1534
1543
  */
@@ -1690,7 +1699,6 @@ var ToggleMode;
1690
1699
  ToggleMode[ToggleMode["self"] = 1] = "self";
1691
1700
  ToggleMode[ToggleMode["children"] = 2] = "children";
1692
1701
  })(ToggleMode || (ToggleMode = {}));
1693
- /* eslint-disable @angular-eslint/prefer-signals */
1694
1702
  /**
1695
1703
  * @deprecated
1696
1704
  */
@@ -1849,7 +1857,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.14", ngImpo
1849
1857
  args: [DOCUMENT]
1850
1858
  }] }] });
1851
1859
 
1852
- /* eslint-disable @angular-eslint/prefer-signals */
1853
1860
  /**
1854
1861
  * @deprecated
1855
1862
  */