@net7/boilerplate-arianna 5.6.2 → 5.6.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.
@@ -65,6 +65,21 @@ export declare class AwSearchLayoutDS extends LayoutDataSource {
65
65
  private getFacetsReq$;
66
66
  doSearchRequest$(): Observable<any>;
67
67
  private _updateSearchPage;
68
+ /**
69
+ * Lets the consumer app customize per-facet input validation from its
70
+ * layout configuration, keyed by `facetId`, without forking the default
71
+ * facets config. Each override replaces that input's `validation` and may
72
+ * provide a `validator(value) => boolean` function and/or a `pattern`
73
+ * (RegExp or string), plus a `message`. Setting an override to a falsy
74
+ * value disables validation for that facet.
75
+ *
76
+ * Example (app config under the layout's config id):
77
+ * facetsValidation: {
78
+ * 'date-from': { pattern: /.../, message: '…' },
79
+ * 'date-to': { validator: (v) => isRealDate(v), message: '…' },
80
+ * }
81
+ */
82
+ private _applyValidationOverrides;
68
83
  private _addFacetsLabels;
69
84
  private _addFacetsOptions;
70
85
  private _normalizeItems;
@@ -28,9 +28,10 @@ export declare abstract class AwFacetInput {
28
28
  getType: () => any;
29
29
  getOutput: () => any;
30
30
  /**
31
- * Pure validity check against the optional config-driven
32
- * `validation: { pattern, message }`. Empty values are always valid
33
- * (use `required` for emptiness). Does not mutate the output.
31
+ * Pure validity check against the optional config-driven `validation`.
32
+ * The consumer may supply either a `validator(value) => boolean` function
33
+ * (takes precedence) or a `pattern` (RegExp or string). Empty values are
34
+ * always valid (use `required` for emptiness). Does not mutate the output.
34
35
  */
35
36
  isValid(value?: any): boolean;
36
37
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@net7/boilerplate-arianna",
3
- "version": "5.6.2",
3
+ "version": "5.6.3",
4
4
  "peerDependencies": {
5
5
  "@angular/common": "^17.3.11",
6
6
  "@angular/core": "^17.3.11"
@@ -165,12 +165,32 @@
165
165
 
166
166
  /* facet links loader */
167
167
  .aw-search {
168
+ /*
169
+ * The loading sentinel carries the `loader-link` class on both the section
170
+ * wrapper and the inner `.n7-facet__input-link` (which holds the label).
171
+ * Hide the label and draw a single spinner on the inner link, instead of
172
+ * the original rule that styled a non-existent nested `.loader-link`.
173
+ */
168
174
  .loader-link {
169
175
  overflow: hidden;
170
- .loader-link {
176
+ border-bottom: 0;
177
+ cursor: default;
178
+ }
179
+
180
+ .n7-facet__input-link.loader-link {
181
+ font-size: 0;
182
+
183
+ .n7-facet__input-link-text,
184
+ .n7-facet__input-link-counter,
185
+ .n7-facet__input-link-icon {
186
+ display: none;
187
+ }
188
+
189
+ &::after {
171
190
  @extend .n7-loader;
172
-
173
- padding: 0;
191
+
192
+ content: '';
193
+ display: block;
174
194
  margin: $space auto 0;
175
195
  width: 40px !important;
176
196
  height: 40px !important;