@aurodesignsystem/auro-library 5.5.3 → 5.5.4
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/CHANGELOG.md +7 -0
- package/package.json +1 -1
- package/scripts/utils/runtimeUtils.mjs +13 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# Semantic Release Automated Changelog
|
|
2
2
|
|
|
3
|
+
## [5.5.4](https://github.com/AlaskaAirlines/auro-library/compare/v5.5.3...v5.5.4) (2025-10-08)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Performance Improvements
|
|
7
|
+
|
|
8
|
+
* add slot text grabber function [#201](https://github.com/AlaskaAirlines/auro-library/issues/201) ([382afe7](https://github.com/AlaskaAirlines/auro-library/commit/382afe7ca8eb85988b109020c4cd55d4df66c7da))
|
|
9
|
+
|
|
3
10
|
## [5.5.3](https://github.com/AlaskaAirlines/auro-library/compare/v5.5.2...v5.5.3) (2025-09-15)
|
|
4
11
|
|
|
5
12
|
|
package/package.json
CHANGED
|
@@ -66,5 +66,18 @@ export default class AuroLibraryRuntimeUtils {
|
|
|
66
66
|
|
|
67
67
|
return elemTag === tag || elem.hasAttribute(tag);
|
|
68
68
|
}
|
|
69
|
+
|
|
70
|
+
/**
|
|
71
|
+
* Gets the text content of a named slot.
|
|
72
|
+
* @returns {String}
|
|
73
|
+
* @private
|
|
74
|
+
*/
|
|
75
|
+
getSlotText(elem, name) {
|
|
76
|
+
const slot = elem.shadowRoot?.querySelector(`slot[name="${name}"]`);
|
|
77
|
+
const nodes = slot?.assignedNodes({ flatten: true }) || [];
|
|
78
|
+
const text = nodes.map(n => n.textContent?.trim()).join(' ').trim();
|
|
79
|
+
|
|
80
|
+
return text || null;
|
|
81
|
+
}
|
|
69
82
|
}
|
|
70
83
|
|