iss-ctrl 0.0.18 → 0.0.20
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/fesm2022/{iss-ctrl-iss-ctrl-C_ZiixeF.mjs → iss-ctrl-iss-ctrl-BnwwafES.mjs} +390 -202
- package/fesm2022/iss-ctrl-iss-ctrl-BnwwafES.mjs.map +1 -0
- package/fesm2022/{iss-ctrl-load-event-DIPikCdF.mjs → iss-ctrl-load-event-BcWMow3s.mjs} +3 -3
- package/fesm2022/{iss-ctrl-load-event-DIPikCdF.mjs.map → iss-ctrl-load-event-BcWMow3s.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-load-options-event-DOlkFXz5.mjs → iss-ctrl-load-options-event-sTdrxJYn.mjs} +3 -3
- package/fesm2022/{iss-ctrl-load-options-event-DOlkFXz5.mjs.map → iss-ctrl-load-options-event-sTdrxJYn.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-load-value-event-BjsuFpPf.mjs → iss-ctrl-load-value-event-BG9zEexV.mjs} +3 -3
- package/fesm2022/{iss-ctrl-load-value-event-BjsuFpPf.mjs.map → iss-ctrl-load-value-event-BG9zEexV.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-note.field-CakHrlcq.mjs → iss-ctrl-note.field-DyOSzuIi.mjs} +2 -2
- package/fesm2022/{iss-ctrl-note.field-CakHrlcq.mjs.map → iss-ctrl-note.field-DyOSzuIi.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-replace-api-keys-C-G34VNS.mjs → iss-ctrl-replace-api-keys-CzJkn7fK.mjs} +2 -2
- package/fesm2022/{iss-ctrl-replace-api-keys-C-G34VNS.mjs.map → iss-ctrl-replace-api-keys-CzJkn7fK.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-set-value-event-C-uD228s.mjs → iss-ctrl-set-value-event-B800MsyP.mjs} +2 -2
- package/fesm2022/{iss-ctrl-set-value-event-C-uD228s.mjs.map → iss-ctrl-set-value-event-B800MsyP.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-table.field-Ce1KnlZO.mjs → iss-ctrl-table.field-CJmtpHsh.mjs} +4 -4
- package/fesm2022/{iss-ctrl-table.field-Ce1KnlZO.mjs.map → iss-ctrl-table.field-CJmtpHsh.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-trigger-based-on-json-value-D5S3shyl.mjs → iss-ctrl-trigger-based-on-json-value-C5x0hyWn.mjs} +2 -2
- package/fesm2022/{iss-ctrl-trigger-based-on-json-value-D5S3shyl.mjs.map → iss-ctrl-trigger-based-on-json-value-C5x0hyWn.mjs.map} +1 -1
- package/fesm2022/{iss-ctrl-user-picker.field-C7DZ3ck2.mjs → iss-ctrl-user-picker.field-CJqIvkMM.mjs} +13 -6
- package/fesm2022/iss-ctrl-user-picker.field-CJqIvkMM.mjs.map +1 -0
- package/fesm2022/iss-ctrl.mjs +1 -1
- package/package.json +1 -1
- package/types/iss-ctrl.d.ts +49 -13
- package/fesm2022/iss-ctrl-iss-ctrl-C_ZiixeF.mjs.map +0 -1
- package/fesm2022/iss-ctrl-user-picker.field-C7DZ3ck2.mjs.map +0 -1
package/fesm2022/iss-ctrl.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { ak as ATTACHMENT_DOWNLOAD_URL, aj as ATTACHMENT_UPLOAD_RESPONSE_MAPPER, ai as ATTACHMENT_UPLOAD_URL, ao as ArabicNumberPipe, a1 as AttachmentViewer, ac as COMPONENTS, a7 as COUNTRIES, e as CheckboxControl, w as CheckboxField, Z as CheckboxViewer, f as ChipsControl, s as ChipsField, U as ChipsViewer, C as ControlBase, a9 as DATETIME_FORMAT, a8 as DATE_FORMAT_ADAPTER, a6 as DEFAULT_COUNTRY, D as DatePickerControl, G as DatePickerField, a4 as DatePickerTimeViewer, a3 as DatePickerViewer, h as DateRangePickerControl, K as DateRangePickerField, a5 as DateRangePickerViewer, i as DatetimePickerControl, J as DatetimePickerField, an as Droppable, E as Employee, ag as FIELD_DATA, F as FieldBase, ap as FieldDataInjector, b as FieldViewer, at as FileHandler, j as FilePickerControl, A as FilePickerField, aJ as FileValidators, d as FormEngine, az as HIJRI_LOCALE, aA as HIJRI_MONTH_NAMES, H as HOST, am as Hints, k as InputControl, p as InputField, N as InputViewer, au as IssDateAdapter, aI as IssValidators, L as Loader, M as MobileControl, v as MobileField, Y as MobileViewer, O as Outlet, P as PLACEHOLDER_REGEX, aa as PLATE_LETTERS, aw as Phone, l as PlateControl, z as PlateField, aq as PlateLetterPipe, a0 as PlateViewer, R as RadioControl, t as RadioField, W as RadioViewer, ad as SERVICES, S as SelectControl, u as SelectField, ar as SelectStatusPipe, X as SelectViewer, m as SlideToggleControl, y as SlideToggleField, $ as SlideToggleViewer, T as TextareaControl, q as TextareaField, Q as TextareaViewer, n as TimePickerControl, B as TimePickerField, a2 as TimePickerViewer, aK as TimeValidator, o as ToggleButtonControl, x as ToggleButtonField, _ as ToggleButtonViewer, as as TranslatePipe, ah as UI_LANGUAGE, al as USER_SEARCH_API, ab as VALIDATION_MESSAGES, ae as VALIDATORS, V as VIEW_PROVIDER, a as ValidationMessage, ax as arrayFrom, aE as createHijriDate, ay as formatFileSize, aF as formatHijriDate, aD as getHijriDaysInMonth, aB as getHijriParts, g as getPropertyByPath, af as isActiveValidationRule, aG as parseHijriDate, av as provideIssDateAdapter, r as replacePlaceholders, aC as startOfHijriMonth, aH as toHijriDisplay } from './iss-ctrl-iss-ctrl-BnwwafES.mjs';
|
|
2
2
|
//# sourceMappingURL=iss-ctrl.mjs.map
|
package/package.json
CHANGED
package/types/iss-ctrl.d.ts
CHANGED
|
@@ -1176,7 +1176,8 @@ declare class FieldEvent {
|
|
|
1176
1176
|
* | `visible()` | `boolean` | Whether the field is rendered at all. |
|
|
1177
1177
|
* | `loading()` | `boolean` | Shows the field's own loading state. |
|
|
1178
1178
|
* | `config` | `FieldConfig` | Per-type configuration — see {@link FieldConfig}. |
|
|
1179
|
-
* | `validation` | `any` | Synchronous validation rules. |
|
|
1179
|
+
* | `validation` | `any` | Synchronous validation rules, exactly as the JSON declared them. |
|
|
1180
|
+
* | `validationFns` | `Record<string, Function>` | Validator factory behind each active rule, resolved by the outlet. |
|
|
1180
1181
|
* | `asyncValidation` | `FieldAsyncValidation` | Remote validation rules. |
|
|
1181
1182
|
* | `events` | `FieldEvent[]` | Cross-field reactions (show, hide, set value, …). |
|
|
1182
1183
|
* | `children` | `IssField[]` | Nested fields, used by table and group fields. |
|
|
@@ -1200,6 +1201,7 @@ declare class IssField {
|
|
|
1200
1201
|
wasVisible: WritableSignal<boolean>;
|
|
1201
1202
|
events: FieldEvent[];
|
|
1202
1203
|
validation: any;
|
|
1204
|
+
validationFns: Record<string, Function>;
|
|
1203
1205
|
asyncValidation: FieldAsyncValidation;
|
|
1204
1206
|
children: IssField[];
|
|
1205
1207
|
apiResponse: BehaviorSubject<any>;
|
|
@@ -1923,11 +1925,11 @@ interface I18n {
|
|
|
1923
1925
|
|
|
1924
1926
|
type ValidationMessageFn<T> = (args: T) => I18n;
|
|
1925
1927
|
|
|
1926
|
-
interface
|
|
1928
|
+
interface IssValidator {
|
|
1927
1929
|
[key: PropertyKey]: ValidationMessageFn<any>;
|
|
1928
1930
|
}
|
|
1929
1931
|
|
|
1930
|
-
declare const VALIDATION_MESSAGES:
|
|
1932
|
+
declare const VALIDATION_MESSAGES: IssValidator;
|
|
1931
1933
|
|
|
1932
1934
|
interface DynamicImport<T> {
|
|
1933
1935
|
[key: PropertyKey]: () => Promise<T>;
|
|
@@ -1965,6 +1967,16 @@ declare const COMPONENTS: DynamicImport<Type<any>>;
|
|
|
1965
1967
|
declare const SERVICES: DynamicImport<Type<any>>;
|
|
1966
1968
|
|
|
1967
1969
|
declare const VALIDATORS: DynamicImport<Function>;
|
|
1970
|
+
/**
|
|
1971
|
+
* Whether a rule in a field's `validation` is switched on.
|
|
1972
|
+
*
|
|
1973
|
+
* The rule's value is the argument its validator is built with, so it is also what says
|
|
1974
|
+
* whether the rule applies at all: `{ "required": false }` is an optional field, not a
|
|
1975
|
+
* required one, and a rule the API left out or sent as null is off the same way. Values
|
|
1976
|
+
* that are falsy but meaningful — `0`, `""` — are rules, so only the three off states are
|
|
1977
|
+
* rejected here.
|
|
1978
|
+
*/
|
|
1979
|
+
declare function isActiveValidationRule(value: unknown): boolean;
|
|
1968
1980
|
|
|
1969
1981
|
declare const HOST: InjectionToken<string>;
|
|
1970
1982
|
|
|
@@ -1978,22 +1990,46 @@ declare const ATTACHMENT_DOWNLOAD_URL: InjectionToken<string>;
|
|
|
1978
1990
|
|
|
1979
1991
|
declare const USER_SEARCH_API: InjectionToken<string>;
|
|
1980
1992
|
|
|
1981
|
-
declare class
|
|
1993
|
+
declare class Hints {
|
|
1982
1994
|
hints: InputSignal<Hint[]>;
|
|
1983
1995
|
touched: InputSignal<boolean>;
|
|
1984
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<
|
|
1985
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<
|
|
1996
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<Hints, never>;
|
|
1997
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<Hints, "iss-ctrl-hints", never, { "hints": { "alias": "hints"; "required": false; "isSignal": true; }; "touched": { "alias": "touched"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
1986
1998
|
}
|
|
1987
1999
|
|
|
1988
|
-
declare class
|
|
2000
|
+
declare class ValidationMessage {
|
|
1989
2001
|
errors: InputSignal<ValidationErrors | null>;
|
|
1990
2002
|
showMessage: InputSignal<boolean>;
|
|
1991
2003
|
getValidationMessage(error: {
|
|
1992
2004
|
key: string;
|
|
1993
2005
|
value: any;
|
|
1994
2006
|
}): any;
|
|
1995
|
-
static ɵfac: i0.ɵɵFactoryDeclaration<
|
|
1996
|
-
static ɵcmp: i0.ɵɵComponentDeclaration<
|
|
2007
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<ValidationMessage, never>;
|
|
2008
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<ValidationMessage, "iss-validation-message-viewer", never, { "errors": { "alias": "errors"; "required": true; "isSignal": true; }; "showMessage": { "alias": "showMessage"; "required": true; "isSignal": true; }; }, {}, never, never, true, never>;
|
|
2009
|
+
}
|
|
2010
|
+
|
|
2011
|
+
/**
|
|
2012
|
+
* `<iss-field-viewer>` — read-only presentation of a single field as a
|
|
2013
|
+
* label / value row.
|
|
2014
|
+
*
|
|
2015
|
+
* Project the caption into the `label` slot and the rendered value into any
|
|
2016
|
+
* element carrying a `value` attribute:
|
|
2017
|
+
*
|
|
2018
|
+
* ```html
|
|
2019
|
+
* <iss-field-viewer>
|
|
2020
|
+
* <label>Request Type</label>
|
|
2021
|
+
* <span>value</span>
|
|
2022
|
+
* </iss-field-viewer>
|
|
2023
|
+
* ```
|
|
2024
|
+
*
|
|
2025
|
+
* The label sits in a fixed-width column, so every value in a stack of viewers
|
|
2026
|
+
* starts on the same vertical line. Override that column with the
|
|
2027
|
+
* `--field-viewer-label-width` custom property on any ancestor.
|
|
2028
|
+
* When no label is projected, the value spans the full width of the row.
|
|
2029
|
+
*/
|
|
2030
|
+
declare class FieldViewer {
|
|
2031
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<FieldViewer, never>;
|
|
2032
|
+
static ɵcmp: i0.ɵɵComponentDeclaration<FieldViewer, "iss-field-viewer", never, {}, {}, never, ["label", "*"], true, never>;
|
|
1997
2033
|
}
|
|
1998
2034
|
|
|
1999
2035
|
declare class Droppable {
|
|
@@ -2203,9 +2239,9 @@ declare abstract class FileValidators {
|
|
|
2203
2239
|
}
|
|
2204
2240
|
|
|
2205
2241
|
declare abstract class TimeValidator {
|
|
2206
|
-
static beforeDate(
|
|
2207
|
-
static afterDate(
|
|
2242
|
+
static beforeDate(otherFieldName: string): ValidatorFn;
|
|
2243
|
+
static afterDate(otherFieldName: string): ValidatorFn;
|
|
2208
2244
|
}
|
|
2209
2245
|
|
|
2210
|
-
export { ATTACHMENT_DOWNLOAD_URL, ATTACHMENT_UPLOAD_RESPONSE_MAPPER, ATTACHMENT_UPLOAD_URL, ArabicNumberPipe, AttachmentViewer, COMPONENTS, COUNTRIES, CheckboxControl, CheckboxField, CheckboxViewer, ChipsControl, ChipsField, ChipsViewer, ControlBase, DATETIME_FORMAT, DATE_FORMAT_ADAPTER, DEFAULT_COUNTRY, DatePickerControl, DatePickerField, DatePickerTimeViewer, DatePickerViewer, DateRangePickerControl, DateRangePickerField, DateRangePickerViewer, DatetimePickerControl, DatetimePickerField, Droppable, Employee, FIELD_DATA, FieldBase, FieldDataInjector, FileHandler, FilePickerControl, FilePickerField, FileValidators, FormEngine, HIJRI_LOCALE, HIJRI_MONTH_NAMES, HOST,
|
|
2211
|
-
export type { ActionTriggerFn, ComponentOutlet, Country, DateRangeEmission, DynamicImport, EventArgument, EventConfigFn, EventStrategy, FieldChange, HijriParts, Hint, HintAlignment, I18n, ISO2, IssAttachment, IssFile, Mobile, Option, PlateLetter,
|
|
2246
|
+
export { ATTACHMENT_DOWNLOAD_URL, ATTACHMENT_UPLOAD_RESPONSE_MAPPER, ATTACHMENT_UPLOAD_URL, ArabicNumberPipe, AttachmentViewer, COMPONENTS, COUNTRIES, CheckboxControl, CheckboxField, CheckboxViewer, ChipsControl, ChipsField, ChipsViewer, ControlBase, DATETIME_FORMAT, DATE_FORMAT_ADAPTER, DEFAULT_COUNTRY, DatePickerControl, DatePickerField, DatePickerTimeViewer, DatePickerViewer, DateRangePickerControl, DateRangePickerField, DateRangePickerViewer, DatetimePickerControl, DatetimePickerField, Droppable, Employee, FIELD_DATA, FieldBase, FieldDataInjector, FieldViewer, FileHandler, FilePickerControl, FilePickerField, FileValidators, FormEngine, HIJRI_LOCALE, HIJRI_MONTH_NAMES, HOST, Hints, InputControl, InputField, InputViewer, IssDateAdapter, IssValidators, Loader, MobileControl, MobileField, MobileViewer, Outlet, PLACEHOLDER_REGEX, PLATE_LETTERS, Phone, PlateControl, PlateField, PlateLetterPipe, PlateViewer, RadioControl, RadioField, RadioViewer, SERVICES, SelectControl, SelectField, SelectStatusPipe, SelectViewer, SlideToggleControl, SlideToggleField, SlideToggleViewer, TextareaControl, TextareaField, TextareaViewer, TimePickerControl, TimePickerField, TimePickerViewer, TimeValidator, ToggleButtonControl, ToggleButtonField, ToggleButtonViewer, TranslatePipe, UI_LANGUAGE, USER_SEARCH_API, VALIDATION_MESSAGES, VALIDATORS, VIEW_PROVIDER, ValidationMessage, arrayFrom, createHijriDate, formatFileSize, formatHijriDate, getHijriDaysInMonth, getHijriParts, getPropertyByPath, isActiveValidationRule, parseHijriDate, provideIssDateAdapter, replacePlaceholders, startOfHijriMonth, toHijriDisplay };
|
|
2247
|
+
export type { ActionTriggerFn, ComponentOutlet, Country, DateRangeEmission, DynamicImport, EventArgument, EventConfigFn, EventStrategy, FieldChange, HijriParts, Hint, HintAlignment, I18n, ISO2, IssAttachment, IssFile, IssValidator, Mobile, Option, PlateLetter, ValidationMessageFn };
|