@agorapulse/ui-components 22.10.4-beta.1 → 22.10.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.
|
Binary file
|
|
@@ -2,7 +2,7 @@ import * as i1 from '@agorapulse/ui-components/directives';
|
|
|
2
2
|
import { BaseButtonDirective } from '@agorapulse/ui-components/directives';
|
|
3
3
|
import { SymbolComponent, withSymbols, apFeatureLock, apErrorFill, SymbolRegistry, apChevronDown, apChevronUp, apFolder, apArrowExpand, apArrowReduce, apSearch } from '@agorapulse/ui-symbol';
|
|
4
4
|
import * as i0 from '@angular/core';
|
|
5
|
-
import { input, inject, ChangeDetectionStrategy, Component,
|
|
5
|
+
import { input, inject, ChangeDetectionStrategy, Component, computed, Directive, effect, untracked, signal, Injectable, contentChildren, ElementRef, DestroyRef, output, viewChild, model, contentChild, afterNextRender } from '@angular/core';
|
|
6
6
|
import { IconButtonComponent } from '@agorapulse/ui-components/icon-button';
|
|
7
7
|
import { InputSearchComponent } from '@agorapulse/ui-components/input-search';
|
|
8
8
|
import { UI_COMPONENTS_SYMBOLS } from '@agorapulse/ui-components/providers';
|
|
@@ -104,31 +104,33 @@ const isInternalNavSelectorEntryALeafDetails = (entry) => entry.type === 'LEAF_D
|
|
|
104
104
|
class TreeNodeAccessibilityDirective {
|
|
105
105
|
apTreeNodeAccessibility = input.required(/* @ts-ignore */
|
|
106
106
|
...(ngDevMode ? [{ debugName: "apTreeNodeAccessibility" }] : /* istanbul ignore next */ []));
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
renderer.setAttribute(nativeEl, 'aria-expanded', `${entry.folded}`);
|
|
118
|
-
}
|
|
119
|
-
renderer.setAttribute(nativeEl, 'role', 'treeitem');
|
|
120
|
-
});
|
|
121
|
-
}
|
|
122
|
-
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TreeNodeAccessibilityDirective, deps: [{ token: i0.ElementRef }, { token: i0.Renderer2 }], target: i0.ɵɵFactoryTarget.Directive });
|
|
123
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.5", type: TreeNodeAccessibilityDirective, isStandalone: true, selector: "[apTreeNodeAccessibility]", inputs: { apTreeNodeAccessibility: { classPropertyName: "apTreeNodeAccessibility", publicName: "apTreeNodeAccessibility", isSignal: true, isRequired: true, transformFunction: null } }, ngImport: i0 });
|
|
107
|
+
ariaExpanded = computed(() => {
|
|
108
|
+
const entry = this.apTreeNodeAccessibility();
|
|
109
|
+
if (!('folded' in entry) || (isInternalNavSelectorEntryALeaf(entry) && !entry.foldable)) {
|
|
110
|
+
return null;
|
|
111
|
+
}
|
|
112
|
+
return !entry.folded;
|
|
113
|
+
}, /* @ts-ignore */
|
|
114
|
+
...(ngDevMode ? [{ debugName: "ariaExpanded" }] : /* istanbul ignore next */ []));
|
|
115
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TreeNodeAccessibilityDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
116
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.5", type: TreeNodeAccessibilityDirective, isStandalone: true, selector: "[apTreeNodeAccessibility]", inputs: { apTreeNodeAccessibility: { classPropertyName: "apTreeNodeAccessibility", publicName: "apTreeNodeAccessibility", isSignal: true, isRequired: true, transformFunction: null } }, host: { attributes: { "role": "treeitem" }, properties: { "attr.aria-level": "apTreeNodeAccessibility().accessibility.ariaLevel", "attr.aria-setsize": "apTreeNodeAccessibility().accessibility.ariaSetsize", "attr.aria-posinset": "apTreeNodeAccessibility().accessibility.ariaPosinset", "attr.tabindex": "apTreeNodeAccessibility().accessibility.tabIndex", "attr.aria-label": "apTreeNodeAccessibility().alias", "attr.aria-expanded": "ariaExpanded()" } }, ngImport: i0 });
|
|
124
117
|
}
|
|
125
118
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.5", ngImport: i0, type: TreeNodeAccessibilityDirective, decorators: [{
|
|
126
119
|
type: Directive,
|
|
127
120
|
args: [{
|
|
128
121
|
selector: '[apTreeNodeAccessibility]',
|
|
129
122
|
standalone: true,
|
|
123
|
+
host: {
|
|
124
|
+
role: 'treeitem',
|
|
125
|
+
'[attr.aria-level]': 'apTreeNodeAccessibility().accessibility.ariaLevel',
|
|
126
|
+
'[attr.aria-setsize]': 'apTreeNodeAccessibility().accessibility.ariaSetsize',
|
|
127
|
+
'[attr.aria-posinset]': 'apTreeNodeAccessibility().accessibility.ariaPosinset',
|
|
128
|
+
'[attr.tabindex]': 'apTreeNodeAccessibility().accessibility.tabIndex',
|
|
129
|
+
'[attr.aria-label]': 'apTreeNodeAccessibility().alias',
|
|
130
|
+
'[attr.aria-expanded]': 'ariaExpanded()',
|
|
131
|
+
},
|
|
130
132
|
}]
|
|
131
|
-
}],
|
|
133
|
+
}], propDecorators: { apTreeNodeAccessibility: [{ type: i0.Input, args: [{ isSignal: true, alias: "apTreeNodeAccessibility", required: true }] }] } });
|
|
132
134
|
|
|
133
135
|
class NavSelectorPopoverTriggerDirective {
|
|
134
136
|
el;
|