Join our webinar on Wednesday, June 26, at 1pm EDTHow Chia Mitigates Risk in the Crypto Industry.Register
Socket
Socket
Sign inDemoInstall

@ui5/webcomponents-base

Package Overview
Dependencies
3
Maintainers
5
Versions
452
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 2.0.0-rc.5 to 2.0.0-rc.6

2

dist/decorators/property.d.ts

@@ -1,2 +0,2 @@

import { Property } from "../UI5ElementMetadata.js";
import type { Property } from "../UI5ElementMetadata.js";
/**

@@ -3,0 +3,0 @@ * Returns a property decorator.

@@ -1,2 +0,2 @@

import { Slot } from "../UI5ElementMetadata.js";
import type { Slot } from "../UI5ElementMetadata.js";
/**

@@ -3,0 +3,0 @@ * Returns a slot decorator.

@@ -134,3 +134,3 @@ import { registerFeature } from "../FeaturesRegistry.js";

deepActive(root) {
if (root.activeElement && root.activeElement.shadowRoot) {
if (root?.activeElement?.shadowRoot?.activeElement) {
return this.deepActive(root.activeElement.shadowRoot);

@@ -137,0 +137,0 @@ }

@@ -1,2 +0,2 @@

import { TemplateResult } from "lit-html";
import type { TemplateResult } from "lit-html";
import type UI5Element from "../UI5Element.js";

@@ -3,0 +3,0 @@ import type OpenUI5Element from "./OpenUI5Element.js";

@@ -1,2 +0,2 @@

import { CLDRData } from "../asset-registries/LocaleData.js";
import type { CLDRData } from "../asset-registries/LocaleData.js";
import type { LegacyDateCalendarCustomizing } from "../features/LegacyDateFormats.js";

@@ -3,0 +3,0 @@ declare class OpenUI5Support {

@@ -10,2 +10,3 @@ type Element = {

getContent: () => Element;
onFocusEvent: (e: FocusEvent) => void;
};

@@ -12,0 +13,0 @@ };

@@ -39,2 +39,12 @@ const openNativePopover = (domRef) => {

};
const patchFocusEvent = (Popup) => {
const origFocusEvent = Popup.prototype.onFocusEvent;
Popup.prototype.onFocusEvent = function onFocusEvent(e) {
const isTypeFocus = e.type === "focus" || e.type === "activate";
const target = e.target;
if (!isTypeFocus || !target.closest("[ui5-popover],[ui5-responsive-popover],[ui5-dialog]")) {
origFocusEvent.call(this, e);
}
};
};
const createGlobalStyles = () => {

@@ -49,4 +59,5 @@ const stylesheet = new CSSStyleSheet();

createGlobalStyles(); // Ensures correct popover positioning by OpenUI5 (otherwise 0,0 is the center of the screen)
patchFocusEvent(Popup); // Popup.prototype.onFocusEvent
};
export default patchPopup;
//# sourceMappingURL=patchPopup.js.map
const VersionInfo = {
version: "2.0.0-rc.5",
version: "2.0.0-rc.6",
major: 2,
minor: 0,
patch: 0,
suffix: "-rc.5",
suffix: "-rc.6",
isNext: false,
buildTime: 1717680065,
buildTime: 1718638412,
};
export default VersionInfo;
//# sourceMappingURL=VersionInfo.js.map
import type { FormatSettings } from "./config/FormatSettings.js";
import AnimationMode from "./types/AnimationMode.js";
import CalendarType from "./types/CalendarType.js";
import type CalendarType from "./types/CalendarType.js";
declare const getAnimationMode: () => AnimationMode;

@@ -5,0 +5,0 @@ declare const getTheme: () => string;

@@ -1,2 +0,2 @@

import { StyleData, StyleDataCSP } from "./types.js";
import type { StyleData, StyleDataCSP } from "./types.js";
declare const createStyle: (data: StyleData, name: string, value?: string, theme?: string) => void;

@@ -3,0 +3,0 @@ declare const updateStyle: (data: StyleData, name: string, value?: string, theme?: string) => void;

@@ -1,2 +0,2 @@

"use strict";import d from"./util/whenDOMReady.js";import c from"./EventProvider.js";import u from"./FontFace.js";import v from"./SystemCSSVars.js";import{getTheme as i}from"./config/Theme.js";import a from"./theming/applyTheme.js";import{registerCurrentRuntime as g}from"./Runtimes.js";import{getFeature as m}from"./FeaturesRegistry.js";import{attachThemeRegistered as y}from"./theming/ThemeRegistered.js";let o=!1,r;const p=new c,h=()=>o,P=e=>{if(!o){p.attachEvent("boot",e);return}e()},l=async()=>{if(r!==void 0)return r;const e=async n=>{if(g(),typeof document>"u"){n();return}y(S);const t=m("OpenUI5Support"),f=t?t.isOpenUI5Detected():!1,s=m("F6Navigation");t&&await t.init(),s&&!f&&s.init(),await d(),await a(i()),t&&t.attachListeners(),u(),v(),n(),o=!0,await p.fireEventAsync("boot")};return r=new Promise(e),r},S=e=>{o&&e===i()&&a(i())};export{l as boot,P as attachBoot,h as isBooted};
"use strict";import d from"./util/whenDOMReady.js";import c from"./EventProvider.js";import u from"./FontFace.js";import v from"./SystemCSSVars.js";import{getTheme as i}from"./config/Theme.js";import a from"./theming/applyTheme.js";import{registerCurrentRuntime as y}from"./Runtimes.js";import{getFeature as p}from"./FeaturesRegistry.js";import{attachThemeRegistered as g}from"./theming/ThemeRegistered.js";let o=!1,r;const m=new c,h=()=>o,P=e=>{if(!o){m.attachEvent("boot",e);return}e()},l=async()=>{if(r!==void 0)return r;const e=async n=>{if(y(),typeof document>"u"){n();return}g(S);const t=p("OpenUI5Support"),f=t?t.isOpenUI5Detected():!1,s=p("F6Navigation");t&&await t.init(),s&&!f&&s.init(),await d(),await a(i()),t&&t.attachListeners(),u(),v(),n(),o=!0,await m.fireEventAsync("boot")};return r=new Promise(e),r},S=e=>{o&&e===i()&&a(i())};export{l as boot,P as attachBoot,h as isBooted};
//# sourceMappingURL=Boot.js.map

@@ -1,2 +0,2 @@

"use strict";import{renderDeferred as m}from"./Render.js";const a=500,i=new Map,c=new Map,E=n=>{const r=n.host,l=n.propName,t=r[l];let o;if(t===void 0||t==="")o=void 0;else if(t instanceof HTMLElement)o=t;else{const d=r.getRootNode();o=d.getElementById&&d.getElementById(t)||void 0}const e=`${r._id}-${l}`,s=i.get(e);if(!o){if(s&&(n.onDisconnect&&n.onDisconnect(s),i.delete(e)),typeof t=="string"&&t&&!c.has(e)){const d=setInterval(()=>{const f=r.getRootNode();f.getElementById&&f.getElementById(t)&&(clearInterval(c.get(e)),c.delete(e),m(r))},a);c.set(e,d)}return}return c.has(e)&&(clearInterval(c.get(e)),c.delete(e)),s!==o&&(s&&n.onDisconnect&&n.onDisconnect(s),n.onConnect&&n.onConnect(o),i.set(e,o)),i.get(e)};export default E;
"use strict";import{renderDeferred as m}from"./Render.js";const a=500,i=new Map,c=new Map,E=n=>{const s=n.host,l=n.propName,t=s[l];let o;if(t===void 0||t==="")o=void 0;else if(t instanceof HTMLElement)o=t;else{const d=s.getRootNode();o=d.getElementById&&d.getElementById(t)||void 0}const e=`${s._id}-${l}`,r=i.get(e);if(!o){if(r&&(n.onDisconnect&&n.onDisconnect(r),i.delete(e)),typeof t=="string"&&t&&!c.has(e)){const d=setInterval(()=>{const f=s.getRootNode();f.getElementById&&f.getElementById(t)&&(clearInterval(c.get(e)),c.delete(e),m(s))},a);c.set(e,d)}return}return c.has(e)&&(clearInterval(c.get(e)),c.delete(e)),r!==o&&(r&&n.onDisconnect&&n.onDisconnect(r),n.onConnect&&n.onConnect(o),i.set(e,o)),i.get(e)};export default E;
//# sourceMappingURL=connectToComponent.js.map

@@ -1,2 +0,2 @@

"use strict";import p from"./getSharedResource.js";import{getCurrentRuntimeIndex as u,compareRuntimes as f,getAllRuntimes as b}from"./Runtimes.js";const m=p("Tags",new Map),d=new Set;let s=new Map,c;const g=-1,h=e=>{d.add(e),m.set(e,u())},w=e=>d.has(e),$=()=>[...d.values()],R=e=>{let n=m.get(e);n===void 0&&(n=g),s.has(n)||s.set(n,new Set),s.get(n).add(e),c||(c=setTimeout(()=>{T(),s=new Map,c=void 0},1e3))},T=()=>{const e=b(),n=u(),l=e[n];let t="Multiple UI5 Web Components instances detected.";e.length>1&&(t=`${t}
"use strict";import p from"./getSharedResource.js";import{getCurrentRuntimeIndex as u,compareRuntimes as f,getAllRuntimes as b}from"./Runtimes.js";const m=p("Tags",new Map),d=new Set;let s=new Map,c;const g=-1,h=e=>{d.add(e),m.set(e,u())},w=e=>d.has(e),$=()=>[...d.values()],y=e=>{let n=m.get(e);n===void 0&&(n=g),s.has(n)||s.set(n,new Set),s.get(n).add(e),c||(c=setTimeout(()=>{R(),s=new Map,c=void 0},1e3))},R=()=>{const e=b(),n=u(),l=e[n];let t="Multiple UI5 Web Components instances detected.";e.length>1&&(t=`${t}
Loading order (versions before 1.1.0 not listed): ${e.map(i=>`

@@ -9,3 +9,3 @@ ${i.description}`).join("")}`),[...s.keys()].forEach(i=>{let o,r;i===g?(o=1,r={description:"Older unknown runtime"}):(o=f(n,i),r=e[i]);let a;o>0?a="an older":o<0?a="a newer":a="the same",t=`${t}

To prevent other runtimes from defining tags that you use, consider using scoping or have third-party libraries use scoping: https://github.com/SAP/ui5-webcomponents/blob/main/docs/2-advanced/03-scoping.md.`,console.warn(t)};export{h as registerTag,w as isTagRegistered,$ as getAllRegisteredTags,R as recordTagRegistrationFailure};
To prevent other runtimes from defining tags that you use, consider using scoping or have third-party libraries use scoping: https://github.com/SAP/ui5-webcomponents/blob/main/docs/2-advanced/03-scoping.md.`,console.warn(t)};export{h as registerTag,w as isTagRegistered,$ as getAllRegisteredTags,y as recordTagRegistrationFailure};
//# sourceMappingURL=CustomElementsRegistry.js.map

@@ -1,2 +0,2 @@

"use strict";const s=a=>(p,e)=>{const t=p.constructor;Object.prototype.hasOwnProperty.call(t,"metadata")||(t.metadata={});const r=t.metadata;r.properties||(r.properties={});const o=r.properties;o[e]||(o[e]=a||{type:String})};export default s;
"use strict";const s=o=>(p,r)=>{const t=p.constructor;Object.prototype.hasOwnProperty.call(t,"metadata")||(t.metadata={});const e=t.metadata;e.properties||(e.properties={});const a=e.properties;a[r]||(a[r]=o||{type:String})};export default s;
//# sourceMappingURL=property.js.map

@@ -1,2 +0,2 @@

"use strict";const f=e=>(l,n)=>{const r=l.constructor;Object.prototype.hasOwnProperty.call(r,"metadata")||(r.metadata={});const o=r.metadata;o.slots||(o.slots={});const t=o.slots;if(e&&e.default&&t.default)throw new Error("Only one slot can be the default slot.");const a=e&&e.default?"default":n;e=e||{type:HTMLElement},e.type||(e.type=HTMLElement),t[a]||(t[a]=e),e.default&&(delete t.default.default,t.default.propertyName=n),r.metadata.managedSlots=!0};export default f;
"use strict";const d=e=>(l,a)=>{const r=l.constructor;Object.prototype.hasOwnProperty.call(r,"metadata")||(r.metadata={});const o=r.metadata;o.slots||(o.slots={});const t=o.slots;if(e&&e.default&&t.default)throw new Error("Only one slot can be the default slot.");const n=e&&e.default?"default":a;e=e||{type:HTMLElement},e.type||(e.type=HTMLElement),t[n]||(t[n]=e),e.default&&(delete t.default.default,t.default.propertyName=a),r.metadata.managedSlots=!0};export default d;
//# sourceMappingURL=slot.js.map

@@ -1,2 +0,2 @@

"use strict";import{registerFeature as a}from"../FeaturesRegistry.js";import{isF6Next as r,isF6Previous as l}from"../Keys.js";import{instanceOfUI5Element as u}from"../UI5Element.js";import{getFirstFocusableElement as h}from"../util/FocusableElements.js";import m from"../util/getFastNavigationGroups.js";import p from"../util/isElementClickable.js";class n{constructor(){this.selectedGroup=null;this.groups=[];this.keydownHandler=this._keydownHandler.bind(this),this.attachEventListeners()}attachEventListeners(){document.addEventListener("keydown",this.keydownHandler)}async groupElementToFocus(e){const s=u(e)?e.getDomRef():e;if(s){if(p(s))return s;const t=await h(s);if(t)return t}}async findNextFocusableGroupElement(e){let s;for(let t=0;t<this.groups.length;t++){let o;if(e>-1?e+1>=this.groups.length?(e=0,o=this.groups[e]):(e+=1,o=this.groups[e]):(e=0,o=this.groups[e]),s=await this.groupElementToFocus(o),s)break}return s}async findPreviousFocusableGroupElement(e){let s;for(let t=0;t<this.groups.length;t++){let o;if(e>0?(e=await this.groupElementToFocus(this.groups[e-1])===await this.groupElementToFocus(this.groups[e])?e-2:e-1,e<0&&(e=this.groups.length-1),o=this.groups[e]):(e=this.groups.length-1,o=this.groups[e]),s=await this.groupElementToFocus(o),s)break}return s}async _keydownHandler(e){const s=r(e),t=l(e);if(!(s||t)||(this.updateGroups(),this.groups.length<1))return;e.preventDefault();let o;if(this.groups.length===0)return o=await this.groupElementToFocus(this.groups[0]),o?.focus();let i=-1;this.selectedGroup&&(i=this.groups.indexOf(this.selectedGroup)),s&&(o=await this.findNextFocusableGroupElement(i)),t&&(o=await this.findPreviousFocusableGroupElement(i)),o?.focus()}removeEventListeners(){document.removeEventListener("keydown",this.keydownHandler)}updateGroups(){this.setSelectedGroup(),this.groups=m(document.body)}setSelectedGroup(e=window.document){const s=window.document.querySelector("html");let t=this.deepActive(e);for(;t&&t.getAttribute("data-sap-ui-fastnavgroup")!=="true"&&t!==s;)t=t.parentElement?t.parentNode:t.parentNode.host;this.selectedGroup=t}deepActive(e){return e.activeElement&&e.activeElement.shadowRoot?this.deepActive(e.activeElement.shadowRoot):e.activeElement}destroy(){this.removeEventListeners()}static init(){return this._instance||(this._instance=new n),this._instance}}a("F6Navigation",n);export default n;
"use strict";import{registerFeature as a}from"../FeaturesRegistry.js";import{isF6Next as r,isF6Previous as l}from"../Keys.js";import{instanceOfUI5Element as u}from"../UI5Element.js";import{getFirstFocusableElement as h}from"../util/FocusableElements.js";import m from"../util/getFastNavigationGroups.js";import p from"../util/isElementClickable.js";class n{constructor(){this.selectedGroup=null;this.groups=[];this.keydownHandler=this._keydownHandler.bind(this),this.attachEventListeners()}attachEventListeners(){document.addEventListener("keydown",this.keydownHandler)}async groupElementToFocus(e){const o=u(e)?e.getDomRef():e;if(o){if(p(o))return o;const t=await h(o);if(t)return t}}async findNextFocusableGroupElement(e){let o;for(let t=0;t<this.groups.length;t++){let s;if(e>-1?e+1>=this.groups.length?(e=0,s=this.groups[e]):(e+=1,s=this.groups[e]):(e=0,s=this.groups[e]),o=await this.groupElementToFocus(s),o)break}return o}async findPreviousFocusableGroupElement(e){let o;for(let t=0;t<this.groups.length;t++){let s;if(e>0?(e=await this.groupElementToFocus(this.groups[e-1])===await this.groupElementToFocus(this.groups[e])?e-2:e-1,e<0&&(e=this.groups.length-1),s=this.groups[e]):(e=this.groups.length-1,s=this.groups[e]),o=await this.groupElementToFocus(s),o)break}return o}async _keydownHandler(e){const o=r(e),t=l(e);if(!(o||t)||(this.updateGroups(),this.groups.length<1))return;e.preventDefault();let s;if(this.groups.length===0)return s=await this.groupElementToFocus(this.groups[0]),s?.focus();let i=-1;this.selectedGroup&&(i=this.groups.indexOf(this.selectedGroup)),o&&(s=await this.findNextFocusableGroupElement(i)),t&&(s=await this.findPreviousFocusableGroupElement(i)),s?.focus()}removeEventListeners(){document.removeEventListener("keydown",this.keydownHandler)}updateGroups(){this.setSelectedGroup(),this.groups=m(document.body)}setSelectedGroup(e=window.document){const o=window.document.querySelector("html");let t=this.deepActive(e);for(;t&&t.getAttribute("data-sap-ui-fastnavgroup")!=="true"&&t!==o;)t=t.parentElement?t.parentNode:t.parentNode.host;this.selectedGroup=t}deepActive(e){return e?.activeElement?.shadowRoot?.activeElement?this.deepActive(e.activeElement.shadowRoot):e.activeElement}destroy(){this.removeEventListeners()}static init(){return this._instance||(this._instance=new n),this._instance}}a("F6Navigation",n);export default n;
//# sourceMappingURL=F6Navigation.js.map

@@ -1,2 +0,2 @@

"use strict";const i=e=>{e.setAttribute("popover","manual"),e.showPopover()},r=e=>{e.hasAttribute("popover")&&(e.hidePopover(),e.removeAttribute("popover"))},a=e=>{const t=e.prototype.open;e.prototype.open=function(...o){t.apply(this,o);const p=!!document.body.querySelector(":popover-open");if(["OPENING","OPEN"].includes(this.getOpenState())&&p){const s=this.getContent();if(s){const c=s.getDomRef();c&&i(c)}}}},y=e=>{const t=e.prototype._closed;e.prototype._closed=function(...o){const n=this.getContent().getDomRef();t.apply(this,o),n&&r(n)}},d=()=>{const e=new CSSStyleSheet;e.replaceSync(".sapMPopup-CTX:popover-open { inset: unset; }"),document.adoptedStyleSheets=[...document.adoptedStyleSheets,e]},u=e=>{a(e),y(e),d()};export default u;
"use strict";const r=e=>{e.setAttribute("popover","manual"),e.showPopover()},a=e=>{e.hasAttribute("popover")&&(e.hidePopover(),e.removeAttribute("popover"))},l=e=>{const o=e.prototype.open;e.prototype.open=function(...t){o.apply(this,t);const p=!!document.body.querySelector(":popover-open");if(["OPENING","OPEN"].includes(this.getOpenState())&&p){const c=this.getContent();if(c){const i=c.getDomRef();i&&r(i)}}}},u=e=>{const o=e.prototype._closed;e.prototype._closed=function(...t){const n=this.getContent().getDomRef();o.apply(this,t),n&&a(n)}},y=e=>{const o=e.prototype.onFocusEvent;e.prototype.onFocusEvent=function(t){const p=t.type==="focus"||t.type==="activate",n=t.target;(!p||!n.closest("[ui5-popover],[ui5-responsive-popover],[ui5-dialog]"))&&o.call(this,t)}},v=()=>{const e=new CSSStyleSheet;e.replaceSync(".sapMPopup-CTX:popover-open { inset: unset; }"),document.adoptedStyleSheets=[...document.adoptedStyleSheets,e]},d=e=>{l(e),u(e),v(),y(e)};export default d;
//# sourceMappingURL=patchPopup.js.map

@@ -1,2 +0,2 @@

"use strict";const e={version:"2.0.0-rc.5",major:2,minor:0,patch:0,suffix:"-rc.5",isNext:!1,buildTime:1717680065};export default e;
"use strict";const e={version:"2.0.0-rc.6",major:2,minor:0,patch:0,suffix:"-rc.6",isNext:!1,buildTime:1718638412};export default e;
//# sourceMappingURL=VersionInfo.js.map

@@ -1,2 +0,2 @@

"use strict";import{getCurrentRuntimeIndex as a,compareRuntimes as g}from"./Runtimes.js";const l=typeof document>"u",o=(e,t)=>t?`${e}|${t}`:e,f=e=>e===void 0?!0:g(a(),parseInt(e))===1,u=(e,t,n="",i)=>{const s=typeof e=="string"?e:e.content,c=a(),r=new CSSStyleSheet;r.replaceSync(s),r._ui5StyleId=o(t,n),i&&(r._ui5RuntimeIndex=c,r._ui5Theme=i),document.adoptedStyleSheets=[...document.adoptedStyleSheets,r]},S=(e,t,n="",i)=>{const s=typeof e=="string"?e:e.content,c=a(),r=document.adoptedStyleSheets.find(d=>d._ui5StyleId===o(t,n));if(r)if(!i)r.replaceSync(s||"");else{const d=r._ui5RuntimeIndex;(r._ui5Theme!==i||f(d))&&(r.replaceSync(s||""),r._ui5RuntimeIndex=String(c),r._ui5Theme=i)}},y=(e,t="")=>l?!0:!!document.adoptedStyleSheets.find(n=>n._ui5StyleId===o(e,t)),p=(e,t="")=>{document.adoptedStyleSheets=document.adoptedStyleSheets.filter(n=>n._ui5StyleId!==o(e,t))},m=(e,t,n="",i)=>{y(t,n)?S(e,t,n,i):u(e,t,n,i)},R=(e,t)=>{if(e===void 0)return t;if(t===void 0)return e;const n=typeof t=="string"?t:t.content;return typeof e=="string"?`${e} ${n}`:{content:`${e.content} ${n}`,packageName:e.packageName,fileName:e.fileName}};export{u as createStyle,y as hasStyle,S as updateStyle,p as removeStyle,m as createOrUpdateStyle,R as mergeStyles};
"use strict";import{getCurrentRuntimeIndex as a,compareRuntimes as g}from"./Runtimes.js";const l=typeof document>"u",o=(e,t)=>t?`${e}|${t}`:e,f=e=>e===void 0?!0:g(a(),parseInt(e))===1,u=(e,t,n="",s)=>{const i=typeof e=="string"?e:e.content,c=a(),r=new CSSStyleSheet;r.replaceSync(i),r._ui5StyleId=o(t,n),s&&(r._ui5RuntimeIndex=c,r._ui5Theme=s),document.adoptedStyleSheets=[...document.adoptedStyleSheets,r]},y=(e,t,n="",s)=>{const i=typeof e=="string"?e:e.content,c=a(),r=document.adoptedStyleSheets.find(d=>d._ui5StyleId===o(t,n));if(r)if(!s)r.replaceSync(i||"");else{const d=r._ui5RuntimeIndex;(r._ui5Theme!==s||f(d))&&(r.replaceSync(i||""),r._ui5RuntimeIndex=String(c),r._ui5Theme=s)}},S=(e,t="")=>l?!0:!!document.adoptedStyleSheets.find(n=>n._ui5StyleId===o(e,t)),p=(e,t="")=>{document.adoptedStyleSheets=document.adoptedStyleSheets.filter(n=>n._ui5StyleId!==o(e,t))},m=(e,t,n="",s)=>{S(t,n)?y(e,t,n,s):u(e,t,n,s)},R=(e,t)=>{if(e===void 0)return t;if(t===void 0)return e;const n=typeof t=="string"?t:t.content;return typeof e=="string"?`${e} ${n}`:{content:`${e.content} ${n}`,packageName:e.packageName,fileName:e.fileName}};export{u as createStyle,S as hasStyle,y as updateStyle,p as removeStyle,m as createOrUpdateStyle,R as mergeStyles};
//# sourceMappingURL=ManagedStyles.js.map

@@ -1,2 +0,2 @@

"use strict";import g from"./EventProvider.js";import v from"./RenderQueue.js";import{getAllRegisteredTags as A}from"./CustomElementsRegistry.js";import{isRtlAware as R}from"./locale/RTLAwareRegistry.js";const s=new Set,d=new g,n=new v;let t,a,m,i;const l=async e=>{n.add(e),await P()},c=e=>{d.fireEvent("beforeComponentRender",e),s.add(e),e._render()},h=e=>{n.remove(e),s.delete(e)},P=async()=>{i||(i=new Promise(e=>{window.requestAnimationFrame(()=>{n.process(c),i=null,e(),m||(m=setTimeout(()=>{m=void 0,n.isEmpty()&&y()},200))})})),await i},I=()=>t||(t=new Promise(e=>{a=e,window.requestAnimationFrame(()=>{n.isEmpty()&&(t=void 0,e())})}),t),U=()=>{const e=A().map(r=>customElements.whenDefined(r));return Promise.all(e)},f=async()=>{await U(),await I()},y=()=>{n.isEmpty()&&a&&(a(),a=void 0,t=void 0)},C=async e=>{s.forEach(r=>{const o=r.constructor,u=o.getMetadata().getTag(),w=R(o),p=o.getMetadata().isLanguageAware(),E=o.getMetadata().isThemeAware();(!e||e.tag===u||e.rtlAware&&w||e.languageAware&&p||e.themeAware&&E)&&l(r)}),await f()},T=e=>{d.attachEvent("beforeComponentRender",e)},b=e=>{d.detachEvent("beforeComponentRender",e)};export{l as renderDeferred,c as renderImmediately,h as cancelRender,f as renderFinished,C as reRenderAllUI5Elements,T as attachBeforeComponentRender,b as detachBeforeComponentRender};
"use strict";import g from"./EventProvider.js";import v from"./RenderQueue.js";import{getAllRegisteredTags as A}from"./CustomElementsRegistry.js";import{isRtlAware as R}from"./locale/RTLAwareRegistry.js";const s=new Set,d=new g,n=new v;let t,a,m,i;const l=async e=>{n.add(e),await P()},c=e=>{d.fireEvent("beforeComponentRender",e),s.add(e),e._render()},h=e=>{n.remove(e),s.delete(e)},P=async()=>{i||(i=new Promise(e=>{window.requestAnimationFrame(()=>{n.process(c),i=null,e(),m||(m=setTimeout(()=>{m=void 0,n.isEmpty()&&U()},200))})})),await i},y=()=>t||(t=new Promise(e=>{a=e,window.requestAnimationFrame(()=>{n.isEmpty()&&(t=void 0,e())})}),t),I=()=>{const e=A().map(r=>customElements.whenDefined(r));return Promise.all(e)},f=async()=>{await I(),await y()},U=()=>{n.isEmpty()&&a&&(a(),a=void 0,t=void 0)},C=async e=>{s.forEach(r=>{const o=r.constructor,u=o.getMetadata().getTag(),w=R(o),p=o.getMetadata().isLanguageAware(),E=o.getMetadata().isThemeAware();(!e||e.tag===u||e.rtlAware&&w||e.languageAware&&p||e.themeAware&&E)&&l(r)}),await f()},T=e=>{d.attachEvent("beforeComponentRender",e)},b=e=>{d.detachEvent("beforeComponentRender",e)};export{l as renderDeferred,c as renderImmediately,h as cancelRender,f as renderFinished,C as reRenderAllUI5Elements,T as attachBeforeComponentRender,b as detachBeforeComponentRender};
//# sourceMappingURL=Render.js.map

@@ -1,2 +0,2 @@

"use strict";import{render as s,html as a,svg as m}from"lit-html";import{getFeature as o}from"../FeaturesRegistry.js";const i=(t,...n)=>{const e=o("LitStatic");return(e?e.html:a)(t,...n)},p=(t,...n)=>{const e=o("LitStatic");return(e?e.svg:m)(t,...n)},l=(t,n,e)=>{const r=o("OpenUI5Enablement");r&&(t=r.wrapTemplateResultInBusyMarkup(i,e.host,t)),s(t,n,e)},f=(t,n,e)=>{const r=o("LitStatic");if(r)return r.unsafeStatic((n||[]).includes(t)?`${t}-${e}`:t)};export{i as html,p as svg};export{f as scopeTag};export{repeat}from"lit-html/directives/repeat.js";export{classMap}from"lit-html/directives/class-map.js";export{styleMap}from"./directives/style-map.js";export{ifDefined}from"lit-html/directives/if-defined.js";export{unsafeHTML}from"lit-html/directives/unsafe-html.js";export default l;
"use strict";import{render as i,html as p,svg as s}from"lit-html";import{getFeature as o}from"../FeaturesRegistry.js";const m=(t,...n)=>{const e=o("LitStatic");return(e?e.html:p)(t,...n)},a=(t,...n)=>{const e=o("LitStatic");return(e?e.svg:s)(t,...n)},l=(t,n,e)=>{const r=o("OpenUI5Enablement");r&&(t=r.wrapTemplateResultInBusyMarkup(m,e.host,t)),i(t,n,e)},f=(t,n,e)=>{const r=o("LitStatic");if(r)return r.unsafeStatic((n||[]).includes(t)?`${t}-${e}`:t)};export{m as html,a as svg};export{f as scopeTag};export{repeat}from"lit-html/directives/repeat.js";export{classMap}from"lit-html/directives/class-map.js";export{styleMap}from"./directives/style-map.js";export{ifDefined}from"lit-html/directives/if-defined.js";export{unsafeHTML}from"lit-html/directives/unsafe-html.js";export default l;
//# sourceMappingURL=LitRenderer.js.map

@@ -1,2 +0,2 @@

"use strict";import r from"./getEffectiveStyle.js";import{attachCustomCSSChange as l}from"./CustomStyle.js";const e=new Map;l(t=>{e.delete(`${t}_normal`)});const S=t=>{const n=`${t.getMetadata().getTag()}_normal`;if(!e.has(n)){const a=r(t),o=new CSSStyleSheet;o.replaceSync(a),e.set(n,[o])}return e.get(n)};export default S;
"use strict";import r from"./getEffectiveStyle.js";import{attachCustomCSSChange as l}from"./CustomStyle.js";const e=new Map;l(t=>{e.delete(`${t}_normal`)});const s=t=>{const n=`${t.getMetadata().getTag()}_normal`;if(!e.has(n)){const a=r(t),o=new CSSStyleSheet;o.replaceSync(a),e.set(n,[o])}return e.get(n)};export default s;
//# sourceMappingURL=getConstructableStyle.js.map

@@ -1,2 +0,2 @@

"use strict";import{getCustomCSS as i,attachCustomCSSChange as f}from"./CustomStyle.js";import r from"./getStylesString.js";import{getFeature as y}from"../FeaturesRegistry.js";const e=new Map;f(t=>{e.delete(`${t}_normal`)});const c=t=>{const o=t.getMetadata().getTag(),n=`${o}_normal`,s=y("OpenUI5Enablement");if(!e.has(n)){let l="";s&&(l=r(s.getBusyIndicatorStyles()));const m=i(o)||"",a=`${r(t.styles)} ${m} ${l}`;e.set(n,a)}return e.get(n)};export default c;
"use strict";import{getCustomCSS as i,attachCustomCSSChange as f}from"./CustomStyle.js";import r from"./getStylesString.js";import{getFeature as p}from"../FeaturesRegistry.js";const e=new Map;f(t=>{e.delete(`${t}_normal`)});const y=t=>{const o=t.getMetadata().getTag(),n=`${o}_normal`,s=p("OpenUI5Enablement");if(!e.has(n)){let l="";s&&(l=r(s.getBusyIndicatorStyles()));const a=i(o)||"",m=`${r(t.styles)} ${a} ${l}`;e.set(n,m)}return e.get(n)};export default y;
//# sourceMappingURL=getEffectiveStyle.js.map

@@ -1,2 +0,2 @@

"use strict";class e{static isValid(t){return!1}static attributeToProperty(t){return t}static propertyToAttribute(t){return t===null?null:String(t)}static valuesAreEqual(t,r){return t===r}static generateTypeAccessors(t){Object.keys(t).forEach(r=>{Object.defineProperty(this,r,{get(){return t[r]}})})}static get isDataTypeClass(){return!0}}export default e;
"use strict";class r{static isValid(t){return!1}static attributeToProperty(t){return t}static propertyToAttribute(t){return t===null?null:String(t)}static valuesAreEqual(t,e){return t===e}static generateTypeAccessors(t){Object.keys(t).forEach(e=>{Object.defineProperty(this,e,{get(){return t[e]}})})}static get isDataTypeClass(){return!0}}export default r;
//# sourceMappingURL=DataType.js.map

@@ -1,2 +0,2 @@

"use strict";import t from"./DataType.js";class e extends t{static isValid(r){return Number(r)===r}static attributeToProperty(r){return parseFloat(r)}}export default e;
"use strict";import r from"./DataType.js";class e extends r{static isValid(t){return Number(t)===t}static attributeToProperty(t){return parseFloat(t)}}export default e;
//# sourceMappingURL=Float.js.map

@@ -1,2 +0,2 @@

"use strict";import e from"./DataType.js";class t extends e{static isValid(r){return Number.isInteger(r)}static attributeToProperty(r){return parseInt(r)}}export default t;
"use strict";import t from"./DataType.js";class r extends t{static isValid(e){return Number.isInteger(e)}static attributeToProperty(e){return parseInt(e)}}export default r;
//# sourceMappingURL=Integer.js.map

@@ -1,2 +0,2 @@

"use strict";import"@ui5/webcomponents-base/dist/ssr-dom.js";import O from"./thirdparty/merge.js";import{boot as L}from"./Boot.js";import U from"./UI5ElementMetadata.js";import S from"./EventProvider.js";import F from"./updateShadowRoot.js";import{shouldIgnoreCustomElement as V}from"./IgnoreCustomElements.js";import{renderDeferred as N,renderImmediately as j,cancelRender as k}from"./Render.js";import{registerTag as x,isTagRegistered as H,recordTagRegistrationFailure as $}from"./CustomElementsRegistry.js";import{observeDOMNode as z,unobserveDOMNode as W}from"./DOMObserver.js";import{skipOriginalEvent as q}from"./config/NoConflict.js";import B from"./locale/getEffectiveDir.js";import{kebabToCamelCase as I,camelToKebabCase as K}from"./util/StringHelper.js";import D from"./util/isValidPropertyName.js";import{getSlotName as G,getSlottedNodesList as b}from"./util/SlotsHelper.js";import A from"./util/arraysAreEqual.js";import{markAsRtlAware as J}from"./locale/RTLAwareRegistry.js";import Q from"./renderer/executeTemplate.js";import{attachFormElementInternals as X,setFormValue as P}from"./features/InputElementsFormSupport.js";let Y=0;const T=new Map,E=new Map;function y(u){this._suppressInvalidation||(this.onInvalidation(u),this._changedState.push(u),N(this),this._invalidationEventProvider.fireEvent("invalidate",{...u,target:this}))}function Z(u,M){do{const t=Object.getOwnPropertyDescriptor(u,M);if(t)return t;u=Object.getPrototypeOf(u)}while(u&&u!==HTMLElement.prototype)}class C extends HTMLElement{constructor(){super();const t=this.constructor;this._changedState=[],this._suppressInvalidation=!0,this._inDOM=!1,this._fullyConnected=!1,this._childChangeListeners=new Map,this._slotChangeListeners=new Map,this._invalidationEventProvider=new S,this._componentStateFinalizedEventProvider=new S;let e;if(this._domRefReadyPromise=new Promise(o=>{e=o}),this._domRefReadyPromise._deferredResolve=e,this._doNotSyncAttributes=new Set,this._slotsAssignedNodes=new WeakMap,this._state={...t.getMetadata().getInitialState()},this._upgradeAllProperties(),t._needsShadowDOM()){const o={mode:"open"};this.attachShadow({...o,...t.getMetadata().getShadowRootOptions()})}}get _id(){return this.__id||(this.__id=`ui5wc_${++Y}`),this.__id}render(){const t=this.constructor.template;return Q(t,this)}async connectedCallback(){const t=this.constructor;this.setAttribute(t.getMetadata().getPureTag(),""),t.getMetadata().supportsF6FastNavigation()&&this.setAttribute("data-sap-ui-fastnavgroup","true");const e=t.getMetadata().slotsAreManaged();this._inDOM=!0,e&&(this._startObservingDOMChildren(),await this._processChildren()),this._inDOM&&(j(this),this._domRefReadyPromise._deferredResolve(),this._fullyConnected=!0,this.onEnterDOM())}disconnectedCallback(){const e=this.constructor.getMetadata().slotsAreManaged();this._inDOM=!1,e&&this._stopObservingDOMChildren(),this._fullyConnected&&(this.onExitDOM(),this._fullyConnected=!1),this._domRefReadyPromise._deferredResolve(),k(this)}onBeforeRendering(){}onAfterRendering(){}onEnterDOM(){}onExitDOM(){}_startObservingDOMChildren(){const e=this.constructor.getMetadata();if(!e.hasSlots())return;const a=e.canSlotText(),s=Object.keys(e.getSlots()).some(d=>e.getSlots()[d].cloned),i={childList:!0,subtree:a||s,characterData:a};z(this,this._processChildren.bind(this),i)}_stopObservingDOMChildren(){W(this)}async _processChildren(){this.constructor.getMetadata().hasSlots()&&await this._updateSlots()}async _updateSlots(){const t=this.constructor,e=t.getMetadata().getSlots(),o=t.getMetadata().canSlotText(),a=Array.from(o?this.childNodes:this.children),s=new Map,i=new Map;for(const[l,m]of Object.entries(e)){const c=m.propertyName||l;i.set(c,l),s.set(c,[...this._state[c]]),this._clearSlot(l,m)}const d=new Map,n=new Map,r=a.map(async(l,m)=>{const c=G(l),f=e[c];if(f===void 0){if(c!=="default"){const p=Object.keys(e).join(", ");console.warn(`Unknown slotName: ${c}, ignoring`,l,`Valid values are: ${p}`)}return}if(f.individualSlots){const p=(d.get(c)||0)+1;d.set(c,p),l._individualSlot=`${c}-${p}`}if(l instanceof HTMLElement){const p=l.localName;if(p.includes("-")&&!V(p)){if(!customElements.get(p)){const w=customElements.whenDefined(p);let _=T.get(p);_||(_=new Promise(R=>setTimeout(R,1e3)),T.set(p,_)),await Promise.race([w,_])}customElements.upgrade(l)}}if(l=t.getMetadata().constructor.validateSlotValue(l,f),v(l)&&f.invalidateOnChildChange){const p=this._getChildChangeListener(c);l.attachInvalidate.call(l,p)}l instanceof HTMLSlotElement&&this._attachSlotChange(l,c,!!f.invalidateOnChildChange);const g=f.propertyName||c;n.has(g)?n.get(g).push({child:l,idx:m}):n.set(g,[{child:l,idx:m}])});await Promise.all(r),n.forEach((l,m)=>{this._state[m]=l.sort((c,f)=>c.idx-f.idx).map(c=>c.child)});let h=!1;for(const[l,m]of Object.entries(e)){const c=m.propertyName||l;A(s.get(c),this._state[c])||(y.call(this,{type:"slot",name:i.get(c),reason:"children"}),h=!0,t.getMetadata().isFormAssociated()&&P(this))}h||y.call(this,{type:"slot",name:"default",reason:"textcontent"})}_clearSlot(t,e){const o=e.propertyName||t;this._state[o].forEach(s=>{if(v(s)){const i=this._getChildChangeListener(t);s.detachInvalidate.call(s,i)}s instanceof HTMLSlotElement&&this._detachSlotChange(s,t)}),this._state[o]=[]}attachInvalidate(t){this._invalidationEventProvider.attachEvent("invalidate",t)}detachInvalidate(t){this._invalidationEventProvider.detachEvent("invalidate",t)}_onChildChange(t,e){this.constructor.getMetadata().shouldInvalidateOnChildChange(t,e.type,e.name)&&y.call(this,{type:"slot",name:t,reason:"childchange",child:e.target})}attributeChangedCallback(t,e,o){let a;if(this._doNotSyncAttributes.has(t))return;const s=this.constructor.getMetadata().getProperties(),i=t.replace(/^ui5-/,""),d=I(i);if(s.hasOwnProperty(d)){const n=s[d],r=n.type;let h=n.validator;r&&r.isDataTypeClass&&(h=r),h?a=h.attributeToProperty(o):r===Boolean?a=o!==null:a=o,this[d]=a}}formAssociatedCallback(){this.constructor.getMetadata().isFormAssociated()&&X(this)}static get formAssociated(){return this.getMetadata().isFormAssociated()}_updateAttribute(t,e){const o=this.constructor;if(!o.getMetadata().hasAttribute(t))return;const s=o.getMetadata().getProperties()[t],i=s.type;let d=s.validator;const n=K(t),r=this.getAttribute(n);if(i&&i.isDataTypeClass&&(d=i),d){const h=d.propertyToAttribute(e);h===null?(this._doNotSyncAttributes.add(n),this.removeAttribute(n),this._doNotSyncAttributes.delete(n)):this.setAttribute(n,h)}else i===Boolean?e===!0&&r===null?this.setAttribute(n,""):e===!1&&r!==null&&this.removeAttribute(n):typeof e!="object"&&r!==e&&this.setAttribute(n,e)}_upgradeProperty(t){if(this.hasOwnProperty(t)){const e=this[t];delete this[t],this[t]=e}}_upgradeAllProperties(){this.constructor.getMetadata().getPropertiesList().forEach(this._upgradeProperty.bind(this))}_getChildChangeListener(t){return this._childChangeListeners.has(t)||this._childChangeListeners.set(t,this._onChildChange.bind(this,t)),this._childChangeListeners.get(t)}_getSlotChangeListener(t){return this._slotChangeListeners.has(t)||this._slotChangeListeners.set(t,this._onSlotChange.bind(this,t)),this._slotChangeListeners.get(t)}_attachSlotChange(t,e,o){const a=this._getSlotChangeListener(e);t.addEventListener("slotchange",s=>{if(a.call(t,s),o){const i=this._slotsAssignedNodes.get(t);i&&i.forEach(n=>{if(v(n)){const r=this._getChildChangeListener(e);n.detachInvalidate.call(n,r)}});const d=b([t]);this._slotsAssignedNodes.set(t,d),d.forEach(n=>{if(v(n)){const r=this._getChildChangeListener(e);n.attachInvalidate.call(n,r)}})}})}_detachSlotChange(t,e){t.removeEventListener("slotchange",this._getSlotChangeListener(e))}_onSlotChange(t){y.call(this,{type:"slot",name:t,reason:"slotchange"})}onInvalidation(t){}_render(){const t=this.constructor,e=t.getMetadata().hasIndividualSlots();this._suppressInvalidation=!0,this.onBeforeRendering(),this._componentStateFinalizedEventProvider.fireEvent("componentStateFinalized"),this._suppressInvalidation=!1,this._changedState=[],t._needsShadowDOM()&&F(this),e&&this._assignIndividualSlotsToChildren(),this.onAfterRendering()}_assignIndividualSlotsToChildren(){Array.from(this.children).forEach(e=>{e._individualSlot&&e.setAttribute("slot",e._individualSlot)})}_waitForDomRef(){return this._domRefReadyPromise}getDomRef(){if(typeof this._getRealDomRef=="function")return this._getRealDomRef();if(!(!this.shadowRoot||this.shadowRoot.children.length===0))return this.shadowRoot.children[0]}getFocusDomRef(){const t=this.getDomRef();if(t)return t.querySelector("[data-sap-focus-ref]")||t}async getFocusDomRefAsync(){return await this._waitForDomRef(),this.getFocusDomRef()}async focus(t){await this._waitForDomRef();const e=this.getFocusDomRef();e&&typeof e.focus=="function"&&e.focus(t)}fireEvent(t,e,o=!1,a=!0){const s=this._fireEvent(t,e,o,a),i=I(t);return i!==t?s&&this._fireEvent(i,e,o,a):s}_fireEvent(t,e,o=!1,a=!0){const s=new CustomEvent(`ui5-${t}`,{detail:e,composed:!1,bubbles:a,cancelable:o}),i=this.dispatchEvent(s);if(q(t))return i;const d=new CustomEvent(t,{detail:e,composed:!1,bubbles:a,cancelable:o});return this.dispatchEvent(d)&&i}getSlottedNodes(t){return b(this[t])}attachComponentStateFinalized(t){this._componentStateFinalizedEventProvider.attachEvent("componentStateFinalized",t)}detachComponentStateFinalized(t){this._componentStateFinalizedEventProvider.detachEvent("componentStateFinalized",t)}get effectiveDir(){return J(this.constructor),B(this)}get isUI5Element(){return!0}get classes(){return{}}get accessibilityInfo(){return{}}static get observedAttributes(){return this.getMetadata().getAttributesList()}static _needsShadowDOM(){return!!this.template||Object.prototype.hasOwnProperty.call(this.prototype,"render")}static _generateAccessors(){const t=this.prototype,e=this.getMetadata().slotsAreManaged(),o=this.getMetadata().getProperties();for(const[a,s]of Object.entries(o)){if(D(a)||console.warn(`"${a}" is not a valid property name. Use a name that does not collide with DOM APIs`),s.type===Boolean&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All booleans are false by default.`);if(s.type===Array)throw new Error(`Wrong type for property "${a}". Properties cannot be of type Array - use "multiple: true" and set "type" to the single value type, such as "String", "Object", etc...`);if(s.type===Object&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All properties of type "Object" are empty objects by default.`);if(s.multiple&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All multiple properties are empty arrays by default.`);const i=Z(t,a);let d;i?.set&&(d=i.set);let n;i?.get&&(n=i.get),Object.defineProperty(t,a,{get(){if(n)return n.call(this);if(this._state[a]!==void 0)return this._state[a];const r=s.defaultValue;return s.type===Boolean?!1:s.type===String?r:s.multiple?[]:r},set(r){let h;const l=this.constructor;r=l.getMetadata().constructor.validatePropertyValue(r,s);const c=s.type;let f=s.validator;const g=n?n.call(this):this._state[a];c&&c.isDataTypeClass&&(f=c),f?h=!f.valuesAreEqual(g,r):Array.isArray(g)&&Array.isArray(r)&&s.multiple&&s.compareValues?h=!A(g,r):h=g!==r,h&&(d?d.call(this,r):this._state[a]=r,y.call(this,{type:"property",name:a,newValue:r,oldValue:g}),l.getMetadata().isFormAssociated()&&P(this),this._updateAttribute(a,r))}})}if(e){const a=this.getMetadata().getSlots();for(const[s,i]of Object.entries(a)){D(s)||console.warn(`"${s}" is not a valid property name. Use a name that does not collide with DOM APIs`);const d=i.propertyName||s;Object.defineProperty(t,d,{get(){return this._state[d]!==void 0?this._state[d]:[]},set(){throw new Error("Cannot set slot content directly, use the DOM APIs (appendChild, removeChild, etc...)")}})}}}static{this.metadata={}}static{this.styles=""}static get dependencies(){return[]}static getUniqueDependencies(){if(!E.has(this)){const t=this.dependencies.filter((e,o,a)=>a.indexOf(e)===o);E.set(this,t)}return E.get(this)||[]}static whenDependenciesDefined(){return Promise.all(this.getUniqueDependencies().map(t=>t.define()))}static async onDefine(){return Promise.resolve()}static async define(){await L(),await Promise.all([this.whenDependenciesDefined(),this.onDefine()]);const t=this.getMetadata().getTag(),e=H(t),o=customElements.get(t);return o&&!e?$(t):o||(this._generateAccessors(),x(t),customElements.define(t,this)),this}static getMetadata(){if(this.hasOwnProperty("_metadata"))return this._metadata;const t=[this.metadata];let e=this;for(;e!==C;)e=Object.getPrototypeOf(e),t.unshift(e.metadata);const o=O({},...t);return this._metadata=new U(o),this._metadata}get validity(){return this._internals?.validity}get validationMessage(){return this._internals?.validationMessage}checkValidity(){return this._internals?.checkValidity()}reportValidity(){return this._internals?.reportValidity()}}const v=u=>"isUI5Element"in u;export default C;export{v as instanceOfUI5Element};
"use strict";import"@ui5/webcomponents-base/dist/ssr-dom.js";import O from"./thirdparty/merge.js";import{boot as L}from"./Boot.js";import U from"./UI5ElementMetadata.js";import S from"./EventProvider.js";import F from"./updateShadowRoot.js";import{shouldIgnoreCustomElement as V}from"./IgnoreCustomElements.js";import{renderDeferred as N,renderImmediately as j,cancelRender as k}from"./Render.js";import{registerTag as x,isTagRegistered as H,recordTagRegistrationFailure as $}from"./CustomElementsRegistry.js";import{observeDOMNode as z,unobserveDOMNode as W}from"./DOMObserver.js";import{skipOriginalEvent as q}from"./config/NoConflict.js";import B from"./locale/getEffectiveDir.js";import{kebabToCamelCase as I,camelToKebabCase as K}from"./util/StringHelper.js";import D from"./util/isValidPropertyName.js";import{getSlotName as G,getSlottedNodesList as b}from"./util/SlotsHelper.js";import A from"./util/arraysAreEqual.js";import{markAsRtlAware as J}from"./locale/RTLAwareRegistry.js";import Q from"./renderer/executeTemplate.js";import{attachFormElementInternals as X,setFormValue as P}from"./features/InputElementsFormSupport.js";let Y=0;const T=new Map,E=new Map;function y(m){this._suppressInvalidation||(this.onInvalidation(m),this._changedState.push(m),N(this),this._invalidationEventProvider.fireEvent("invalidate",{...m,target:this}))}function Z(m,M){do{const t=Object.getOwnPropertyDescriptor(m,M);if(t)return t;m=Object.getPrototypeOf(m)}while(m&&m!==HTMLElement.prototype)}class C extends HTMLElement{constructor(){super();const t=this.constructor;this._changedState=[],this._suppressInvalidation=!0,this._inDOM=!1,this._fullyConnected=!1,this._childChangeListeners=new Map,this._slotChangeListeners=new Map,this._invalidationEventProvider=new S,this._componentStateFinalizedEventProvider=new S;let e;if(this._domRefReadyPromise=new Promise(o=>{e=o}),this._domRefReadyPromise._deferredResolve=e,this._doNotSyncAttributes=new Set,this._slotsAssignedNodes=new WeakMap,this._state={...t.getMetadata().getInitialState()},this._upgradeAllProperties(),t._needsShadowDOM()){const o={mode:"open"};this.attachShadow({...o,...t.getMetadata().getShadowRootOptions()})}}get _id(){return this.__id||(this.__id=`ui5wc_${++Y}`),this.__id}render(){const t=this.constructor.template;return Q(t,this)}async connectedCallback(){const t=this.constructor;this.setAttribute(t.getMetadata().getPureTag(),""),t.getMetadata().supportsF6FastNavigation()&&this.setAttribute("data-sap-ui-fastnavgroup","true");const e=t.getMetadata().slotsAreManaged();this._inDOM=!0,e&&(this._startObservingDOMChildren(),await this._processChildren()),this._inDOM&&(j(this),this._domRefReadyPromise._deferredResolve(),this._fullyConnected=!0,this.onEnterDOM())}disconnectedCallback(){const e=this.constructor.getMetadata().slotsAreManaged();this._inDOM=!1,e&&this._stopObservingDOMChildren(),this._fullyConnected&&(this.onExitDOM(),this._fullyConnected=!1),this._domRefReadyPromise._deferredResolve(),k(this)}onBeforeRendering(){}onAfterRendering(){}onEnterDOM(){}onExitDOM(){}_startObservingDOMChildren(){const e=this.constructor.getMetadata();if(!e.hasSlots())return;const a=e.canSlotText(),s=Object.keys(e.getSlots()).some(d=>e.getSlots()[d].cloned),i={childList:!0,subtree:a||s,characterData:a};z(this,this._processChildren.bind(this),i)}_stopObservingDOMChildren(){W(this)}async _processChildren(){this.constructor.getMetadata().hasSlots()&&await this._updateSlots()}async _updateSlots(){const t=this.constructor,e=t.getMetadata().getSlots(),o=t.getMetadata().canSlotText(),a=Array.from(o?this.childNodes:this.children),s=new Map,i=new Map;for(const[l,u]of Object.entries(e)){const c=u.propertyName||l;i.set(c,l),s.set(c,[...this._state[c]]),this._clearSlot(l,u)}const d=new Map,n=new Map,r=a.map(async(l,u)=>{const c=G(l),f=e[c];if(f===void 0){if(c!=="default"){const p=Object.keys(e).join(", ");console.warn(`Unknown slotName: ${c}, ignoring`,l,`Valid values are: ${p}`)}return}if(f.individualSlots){const p=(d.get(c)||0)+1;d.set(c,p),l._individualSlot=`${c}-${p}`}if(l instanceof HTMLElement){const p=l.localName;if(p.includes("-")&&!V(p)){if(!customElements.get(p)){const w=customElements.whenDefined(p);let _=T.get(p);_||(_=new Promise(R=>setTimeout(R,1e3)),T.set(p,_)),await Promise.race([w,_])}customElements.upgrade(l)}}if(l=t.getMetadata().constructor.validateSlotValue(l,f),v(l)&&f.invalidateOnChildChange){const p=this._getChildChangeListener(c);l.attachInvalidate.call(l,p)}l instanceof HTMLSlotElement&&this._attachSlotChange(l,c,!!f.invalidateOnChildChange);const g=f.propertyName||c;n.has(g)?n.get(g).push({child:l,idx:u}):n.set(g,[{child:l,idx:u}])});await Promise.all(r),n.forEach((l,u)=>{this._state[u]=l.sort((c,f)=>c.idx-f.idx).map(c=>c.child)});let h=!1;for(const[l,u]of Object.entries(e)){const c=u.propertyName||l;A(s.get(c),this._state[c])||(y.call(this,{type:"slot",name:i.get(c),reason:"children"}),h=!0,t.getMetadata().isFormAssociated()&&P(this))}h||y.call(this,{type:"slot",name:"default",reason:"textcontent"})}_clearSlot(t,e){const o=e.propertyName||t;this._state[o].forEach(s=>{if(v(s)){const i=this._getChildChangeListener(t);s.detachInvalidate.call(s,i)}s instanceof HTMLSlotElement&&this._detachSlotChange(s,t)}),this._state[o]=[]}attachInvalidate(t){this._invalidationEventProvider.attachEvent("invalidate",t)}detachInvalidate(t){this._invalidationEventProvider.detachEvent("invalidate",t)}_onChildChange(t,e){this.constructor.getMetadata().shouldInvalidateOnChildChange(t,e.type,e.name)&&y.call(this,{type:"slot",name:t,reason:"childchange",child:e.target})}attributeChangedCallback(t,e,o){let a;if(this._doNotSyncAttributes.has(t))return;const s=this.constructor.getMetadata().getProperties(),i=t.replace(/^ui5-/,""),d=I(i);if(s.hasOwnProperty(d)){const n=s[d],r=n.type;let h=n.validator;r&&r.isDataTypeClass&&(h=r),h?a=h.attributeToProperty(o):r===Boolean?a=o!==null:a=o,this[d]=a}}formAssociatedCallback(){this.constructor.getMetadata().isFormAssociated()&&X(this)}static get formAssociated(){return this.getMetadata().isFormAssociated()}_updateAttribute(t,e){const o=this.constructor;if(!o.getMetadata().hasAttribute(t))return;const s=o.getMetadata().getProperties()[t],i=s.type;let d=s.validator;const n=K(t),r=this.getAttribute(n);if(i&&i.isDataTypeClass&&(d=i),d){const h=d.propertyToAttribute(e);h===null?(this._doNotSyncAttributes.add(n),this.removeAttribute(n),this._doNotSyncAttributes.delete(n)):this.setAttribute(n,h)}else i===Boolean?e===!0&&r===null?this.setAttribute(n,""):e===!1&&r!==null&&this.removeAttribute(n):typeof e!="object"&&r!==e&&this.setAttribute(n,e)}_upgradeProperty(t){if(this.hasOwnProperty(t)){const e=this[t];delete this[t],this[t]=e}}_upgradeAllProperties(){this.constructor.getMetadata().getPropertiesList().forEach(this._upgradeProperty.bind(this))}_getChildChangeListener(t){return this._childChangeListeners.has(t)||this._childChangeListeners.set(t,this._onChildChange.bind(this,t)),this._childChangeListeners.get(t)}_getSlotChangeListener(t){return this._slotChangeListeners.has(t)||this._slotChangeListeners.set(t,this._onSlotChange.bind(this,t)),this._slotChangeListeners.get(t)}_attachSlotChange(t,e,o){const a=this._getSlotChangeListener(e);t.addEventListener("slotchange",s=>{if(a.call(t,s),o){const i=this._slotsAssignedNodes.get(t);i&&i.forEach(n=>{if(v(n)){const r=this._getChildChangeListener(e);n.detachInvalidate.call(n,r)}});const d=b([t]);this._slotsAssignedNodes.set(t,d),d.forEach(n=>{if(v(n)){const r=this._getChildChangeListener(e);n.attachInvalidate.call(n,r)}})}})}_detachSlotChange(t,e){t.removeEventListener("slotchange",this._getSlotChangeListener(e))}_onSlotChange(t){y.call(this,{type:"slot",name:t,reason:"slotchange"})}onInvalidation(t){}_render(){const t=this.constructor,e=t.getMetadata().hasIndividualSlots();this._suppressInvalidation=!0,this.onBeforeRendering(),this._componentStateFinalizedEventProvider.fireEvent("componentStateFinalized"),this._suppressInvalidation=!1,this._changedState=[],t._needsShadowDOM()&&F(this),e&&this._assignIndividualSlotsToChildren(),this.onAfterRendering()}_assignIndividualSlotsToChildren(){Array.from(this.children).forEach(e=>{e._individualSlot&&e.setAttribute("slot",e._individualSlot)})}_waitForDomRef(){return this._domRefReadyPromise}getDomRef(){if(typeof this._getRealDomRef=="function")return this._getRealDomRef();if(!(!this.shadowRoot||this.shadowRoot.children.length===0))return this.shadowRoot.children[0]}getFocusDomRef(){const t=this.getDomRef();if(t)return t.querySelector("[data-sap-focus-ref]")||t}async getFocusDomRefAsync(){return await this._waitForDomRef(),this.getFocusDomRef()}async focus(t){await this._waitForDomRef();const e=this.getFocusDomRef();e===this?HTMLElement.prototype.focus.call(this,t):e&&typeof e.focus=="function"&&e.focus(t)}fireEvent(t,e,o=!1,a=!0){const s=this._fireEvent(t,e,o,a),i=I(t);return i!==t?s&&this._fireEvent(i,e,o,a):s}_fireEvent(t,e,o=!1,a=!0){const s=new CustomEvent(`ui5-${t}`,{detail:e,composed:!1,bubbles:a,cancelable:o}),i=this.dispatchEvent(s);if(q(t))return i;const d=new CustomEvent(t,{detail:e,composed:!1,bubbles:a,cancelable:o});return this.dispatchEvent(d)&&i}getSlottedNodes(t){return b(this[t])}attachComponentStateFinalized(t){this._componentStateFinalizedEventProvider.attachEvent("componentStateFinalized",t)}detachComponentStateFinalized(t){this._componentStateFinalizedEventProvider.detachEvent("componentStateFinalized",t)}get effectiveDir(){return J(this.constructor),B(this)}get isUI5Element(){return!0}get classes(){return{}}get accessibilityInfo(){return{}}static get observedAttributes(){return this.getMetadata().getAttributesList()}static _needsShadowDOM(){return!!this.template||Object.prototype.hasOwnProperty.call(this.prototype,"render")}static _generateAccessors(){const t=this.prototype,e=this.getMetadata().slotsAreManaged(),o=this.getMetadata().getProperties();for(const[a,s]of Object.entries(o)){if(D(a)||console.warn(`"${a}" is not a valid property name. Use a name that does not collide with DOM APIs`),s.type===Boolean&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All booleans are false by default.`);if(s.type===Array)throw new Error(`Wrong type for property "${a}". Properties cannot be of type Array - use "multiple: true" and set "type" to the single value type, such as "String", "Object", etc...`);if(s.type===Object&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All properties of type "Object" are empty objects by default.`);if(s.multiple&&s.defaultValue)throw new Error(`Cannot set a default value for property "${a}". All multiple properties are empty arrays by default.`);const i=Z(t,a);let d;i?.set&&(d=i.set);let n;i?.get&&(n=i.get),Object.defineProperty(t,a,{get(){if(n)return n.call(this);if(this._state[a]!==void 0)return this._state[a];const r=s.defaultValue;return s.type===Boolean?!1:s.type===String?r:s.multiple?[]:r},set(r){let h;const l=this.constructor;r=l.getMetadata().constructor.validatePropertyValue(r,s);const c=s.type;let f=s.validator;const g=n?n.call(this):this._state[a];c&&c.isDataTypeClass&&(f=c),f?h=!f.valuesAreEqual(g,r):Array.isArray(g)&&Array.isArray(r)&&s.multiple&&s.compareValues?h=!A(g,r):h=g!==r,h&&(d?d.call(this,r):this._state[a]=r,y.call(this,{type:"property",name:a,newValue:r,oldValue:g}),l.getMetadata().isFormAssociated()&&P(this),this._updateAttribute(a,r))}})}if(e){const a=this.getMetadata().getSlots();for(const[s,i]of Object.entries(a)){D(s)||console.warn(`"${s}" is not a valid property name. Use a name that does not collide with DOM APIs`);const d=i.propertyName||s;Object.defineProperty(t,d,{get(){return this._state[d]!==void 0?this._state[d]:[]},set(){throw new Error("Cannot set slot content directly, use the DOM APIs (appendChild, removeChild, etc...)")}})}}}static{this.metadata={}}static{this.styles=""}static get dependencies(){return[]}static getUniqueDependencies(){if(!E.has(this)){const t=this.dependencies.filter((e,o,a)=>a.indexOf(e)===o);E.set(this,t)}return E.get(this)||[]}static whenDependenciesDefined(){return Promise.all(this.getUniqueDependencies().map(t=>t.define()))}static async onDefine(){return Promise.resolve()}static async define(){await L(),await Promise.all([this.whenDependenciesDefined(),this.onDefine()]);const t=this.getMetadata().getTag(),e=H(t),o=customElements.get(t);return o&&!e?$(t):o||(this._generateAccessors(),x(t),customElements.define(t,this)),this}static getMetadata(){if(this.hasOwnProperty("_metadata"))return this._metadata;const t=[this.metadata];let e=this;for(;e!==C;)e=Object.getPrototypeOf(e),t.unshift(e.metadata);const o=O({},...t);return this._metadata=new U(o),this._metadata}get validity(){return this._internals?.validity}get validationMessage(){return this._internals?.validationMessage}checkValidity(){return this._internals?.checkValidity()}reportValidity(){return this._internals?.reportValidity()}}const v=m=>"isUI5Element"in m;export default C;export{v as instanceOfUI5Element};
//# sourceMappingURL=UI5Element.js.map

@@ -1,2 +0,2 @@

"use strict";import{camelToKebabCase as p}from"./util/StringHelper.js";import{getSlottedNodes as d}from"./util/SlotsHelper.js";import{getEffectiveScopingSuffixForTag as u}from"./CustomElementsScopeUtils.js";class f{constructor(t){this.metadata=t}getInitialState(){if(Object.prototype.hasOwnProperty.call(this,"_initialState"))return this._initialState;const t={},a=this.slotsAreManaged(),o=this.getProperties();for(const e in o){const i=o[e].type,n=o[e].defaultValue;i===Boolean?(t[e]=!1,n!==void 0&&console.warn("The 'defaultValue' metadata key is ignored for all booleans properties, they would be initialized with 'false' by default")):o[e].multiple?Object.defineProperty(t,e,{enumerable:!0,get(){return[]}}):i===Object?Object.defineProperty(t,e,{enumerable:!0,get(){return"defaultValue"in o[e]?o[e].defaultValue:{}}}):i===String?t[e]="defaultValue"in o[e]?o[e].defaultValue:"":t[e]=n}if(a){const e=this.getSlots();for(const[i,n]of Object.entries(e)){const l=n.propertyName||i;t[l]=[]}}return this._initialState=t,t}static validatePropertyValue(t,a){return a.multiple&&t?t.map(e=>s(e,a)):s(t,a)}static validateSlotValue(t,a){return g(t,a)}getPureTag(){return this.metadata.tag||""}getTag(){const t=this.metadata.tag;if(!t)return"";const a=u(t);return a?`${t}-${a}`:t}hasAttribute(t){const a=this.getProperties()[t];return a.type!==Object&&!a.noAttribute&&!a.multiple}getPropertiesList(){return Object.keys(this.getProperties())}getAttributesList(){return this.getPropertiesList().filter(this.hasAttribute.bind(this)).map(p)}canSlotText(){return this.getSlots().default?.type===Node}hasSlots(){return!!Object.entries(this.getSlots()).length}hasIndividualSlots(){return this.slotsAreManaged()&&Object.values(this.getSlots()).some(t=>t.individualSlots)}slotsAreManaged(){return!!this.metadata.managedSlots}supportsF6FastNavigation(){return!!this.metadata.fastNavigation}getProperties(){return this.metadata.properties||(this.metadata.properties={}),this.metadata.properties}getEvents(){return this.metadata.events||(this.metadata.events={}),this.metadata.events}getSlots(){return this.metadata.slots||(this.metadata.slots={}),this.metadata.slots}isLanguageAware(){return!!this.metadata.languageAware}isThemeAware(){return!!this.metadata.themeAware}getShadowRootOptions(){return this.metadata.shadowRootOptions||{}}isFormAssociated(){return!!this.metadata.formAssociated}shouldInvalidateOnChildChange(t,a,o){const e=this.getSlots()[t].invalidateOnChildChange;if(e===void 0)return!1;if(typeof e=="boolean")return e;if(typeof e=="object"){if(a==="property"){if(e.properties===void 0)return!1;if(typeof e.properties=="boolean")return e.properties;if(Array.isArray(e.properties))return e.properties.includes(o);throw new Error("Wrong format for invalidateOnChildChange.properties: boolean or array is expected")}if(a==="slot"){if(e.slots===void 0)return!1;if(typeof e.slots=="boolean")return e.slots;if(Array.isArray(e.slots))return e.slots.includes(o);throw new Error("Wrong format for invalidateOnChildChange.slots: boolean or array is expected")}}throw new Error("Wrong format for invalidateOnChildChange: boolean or object is expected")}}const s=(r,t)=>{const a=t.type;let o=t.validator;return a&&a.isDataTypeClass&&(o=a),o?o.isValid(r)?r:t.defaultValue:!a||a===String?typeof r=="string"||typeof r>"u"||r===null?r:r.toString():a===Boolean?typeof r=="boolean"?r:!1:a===Object?typeof r=="object"?r:t.defaultValue:r in a?r:t.defaultValue},g=(r,t)=>(r&&d(r).forEach(a=>{if(!(a instanceof t.type))throw new Error(`The element is not of type ${t.type.toString()}`)}),r);export default f;
"use strict";import{camelToKebabCase as p}from"./util/StringHelper.js";import{getSlottedNodes as d}from"./util/SlotsHelper.js";import{getEffectiveScopingSuffixForTag as u}from"./CustomElementsScopeUtils.js";class f{constructor(t){this.metadata=t}getInitialState(){if(Object.prototype.hasOwnProperty.call(this,"_initialState"))return this._initialState;const t={},a=this.slotsAreManaged(),o=this.getProperties();for(const e in o){const i=o[e].type,n=o[e].defaultValue;i===Boolean?(t[e]=!1,n!==void 0&&console.warn("The 'defaultValue' metadata key is ignored for all booleans properties, they would be initialized with 'false' by default")):o[e].multiple?Object.defineProperty(t,e,{enumerable:!0,get(){return[]}}):i===Object?Object.defineProperty(t,e,{enumerable:!0,get(){return"defaultValue"in o[e]?o[e].defaultValue:{}}}):i===String?t[e]="defaultValue"in o[e]?o[e].defaultValue:"":t[e]=n}if(a){const e=this.getSlots();for(const[i,n]of Object.entries(e)){const l=n.propertyName||i;t[l]=[]}}return this._initialState=t,t}static validatePropertyValue(t,a){return a.multiple&&t?t.map(e=>s(e,a)):s(t,a)}static validateSlotValue(t,a){return y(t,a)}getPureTag(){return this.metadata.tag||""}getTag(){const t=this.metadata.tag;if(!t)return"";const a=u(t);return a?`${t}-${a}`:t}hasAttribute(t){const a=this.getProperties()[t];return a.type!==Object&&!a.noAttribute&&!a.multiple}getPropertiesList(){return Object.keys(this.getProperties())}getAttributesList(){return this.getPropertiesList().filter(this.hasAttribute.bind(this)).map(p)}canSlotText(){return this.getSlots().default?.type===Node}hasSlots(){return!!Object.entries(this.getSlots()).length}hasIndividualSlots(){return this.slotsAreManaged()&&Object.values(this.getSlots()).some(t=>t.individualSlots)}slotsAreManaged(){return!!this.metadata.managedSlots}supportsF6FastNavigation(){return!!this.metadata.fastNavigation}getProperties(){return this.metadata.properties||(this.metadata.properties={}),this.metadata.properties}getEvents(){return this.metadata.events||(this.metadata.events={}),this.metadata.events}getSlots(){return this.metadata.slots||(this.metadata.slots={}),this.metadata.slots}isLanguageAware(){return!!this.metadata.languageAware}isThemeAware(){return!!this.metadata.themeAware}getShadowRootOptions(){return this.metadata.shadowRootOptions||{}}isFormAssociated(){return!!this.metadata.formAssociated}shouldInvalidateOnChildChange(t,a,o){const e=this.getSlots()[t].invalidateOnChildChange;if(e===void 0)return!1;if(typeof e=="boolean")return e;if(typeof e=="object"){if(a==="property"){if(e.properties===void 0)return!1;if(typeof e.properties=="boolean")return e.properties;if(Array.isArray(e.properties))return e.properties.includes(o);throw new Error("Wrong format for invalidateOnChildChange.properties: boolean or array is expected")}if(a==="slot"){if(e.slots===void 0)return!1;if(typeof e.slots=="boolean")return e.slots;if(Array.isArray(e.slots))return e.slots.includes(o);throw new Error("Wrong format for invalidateOnChildChange.slots: boolean or array is expected")}}throw new Error("Wrong format for invalidateOnChildChange: boolean or object is expected")}}const s=(r,t)=>{const a=t.type;let o=t.validator;return a&&a.isDataTypeClass&&(o=a),o?o.isValid(r)?r:t.defaultValue:!a||a===String?typeof r=="string"||typeof r>"u"||r===null?r:r.toString():a===Boolean?typeof r=="boolean"?r:!1:a===Object?typeof r=="object"?r:t.defaultValue:r in a?r:t.defaultValue},y=(r,t)=>(r&&d(r).forEach(a=>{if(!(a instanceof t.type))throw new Error(`The element is not of type ${t.type.toString()}`)}),r);export default f;
//# sourceMappingURL=UI5ElementMetadata.js.map

@@ -1,2 +0,2 @@

"use strict";const r=new WeakMap,o=new WeakMap,u={attributes:!0,childList:!0,characterData:!0,subtree:!0},v=e=>{const t=e;return t.accessibleNameRef?b(e):t.accessibleName?t.accessibleName:void 0},b=e=>{const t=e.accessibleNameRef?.split(" ")??[],s=e.getRootNode();let l="";return t.forEach((n,c)=>{const a=s.querySelector(`[id='${n}']`),d=`${a&&a.textContent?a.textContent:""}`;d&&(l+=d,c<t.length-1&&(l+=" "))}),l},m=e=>{const t=new Set;return E(e).forEach(c=>{t.add(c)}),(e.accessibleNameRef?.split(" ")??[]).forEach(c=>{const a=g(e,c);a&&t.add(a)}),Array.from(t)},E=e=>{const t=e.getRootNode().querySelectorAll(`[for="${e.id}"]`);return Array.from(t)},g=(e,t)=>e.getRootNode().querySelector(`[id='${t}']`),M=e=>{const t=[];if(E(e).forEach(l=>{const n=l.textContent;n&&t.push(n)}),t.length)return t.join(" ")},k=e=>s=>{if(!(s&&s.type==="property"&&s.name==="accessibleNameRef"))return;const l=o.get(e);if(!l)return;const n=l.observedElements,c=m(e);n.forEach(a=>{c.includes(a)||i(l,a)}),c.forEach(a=>{n.includes(a)||(f(l,a),l.observedElements.push(a))}),l?.callback()},A=(e,t)=>{if(o.has(e))return;const s=m(e),l=k(e),n={host:e,observedElements:s,callback:t,invalidationCallback:l};o.set(e,n),e.attachInvalidate(l),s.forEach(c=>{f(n,c)}),t()},f=(e,t)=>{let s=r.get(t);if(!s){s={observer:null,callbacks:[]};const l=new MutationObserver(()=>{s.callbacks.forEach(a=>{a()});const c=document.getElementById(t.id);e.host.id===t.getAttribute("for")||c||i(e,t)});s.observer=l,l.observe(t,u),r.set(t,s)}s.callbacks.includes(e.callback)||s.callbacks.push(e.callback)},i=(e,t)=>{const s=r.get(t);s&&(s.callbacks=s.callbacks.filter(l=>l!==e.callback),s.callbacks.length||(s.observer?.disconnect(),r.delete(t))),e.observedElements=e.observedElements.filter(l=>l!==t)},T=e=>{const t=o.get(e);if(!t)return;[...t.observedElements].forEach(l=>{i(t,l)}),e.detachInvalidate(t.invalidationCallback),o.delete(e)};export{v as getEffectiveAriaLabelText,M as getAssociatedLabelForTexts,A as registerUI5Element,T as deregisterUI5Element,b as getAllAccessibleNameRefTexts};
"use strict";const r=new WeakMap,o=new WeakMap,u={attributes:!0,childList:!0,characterData:!0,subtree:!0},v=e=>{const t=e;return t.accessibleNameRef?m(e):t.accessibleName?t.accessibleName:void 0},m=e=>{const t=e.accessibleNameRef?.split(" ")??[],s=e.getRootNode();let l="";return t.forEach((a,c)=>{const n=s.querySelector(`[id='${a}']`),d=`${n&&n.textContent?n.textContent:""}`;d&&(l+=d,c<t.length-1&&(l+=" "))}),l},E=e=>{const t=new Set;return b(e).forEach(c=>{t.add(c)}),(e.accessibleNameRef?.split(" ")??[]).forEach(c=>{const n=g(e,c);n&&t.add(n)}),Array.from(t)},b=e=>{const t=e.getRootNode().querySelectorAll(`[for="${e.id}"]`);return Array.from(t)},g=(e,t)=>e.getRootNode().querySelector(`[id='${t}']`),M=e=>{const t=[];if(b(e).forEach(l=>{const a=l.textContent;a&&t.push(a)}),t.length)return t.join(" ")},k=e=>s=>{if(!(s&&s.type==="property"&&s.name==="accessibleNameRef"))return;const l=o.get(e);if(!l)return;const a=l.observedElements,c=E(e);a.forEach(n=>{c.includes(n)||i(l,n)}),c.forEach(n=>{a.includes(n)||(f(l,n),l.observedElements.push(n))}),l?.callback()},A=(e,t)=>{if(o.has(e))return;const s=E(e),l=k(e),a={host:e,observedElements:s,callback:t,invalidationCallback:l};o.set(e,a),e.attachInvalidate(l),s.forEach(c=>{f(a,c)}),t()},f=(e,t)=>{let s=r.get(t);if(!s){s={observer:null,callbacks:[]};const l=new MutationObserver(()=>{s.callbacks.forEach(n=>{n()});const c=document.getElementById(t.id);e.host.id===t.getAttribute("for")||c||i(e,t)});s.observer=l,l.observe(t,u),r.set(t,s)}s.callbacks.includes(e.callback)||s.callbacks.push(e.callback)},i=(e,t)=>{const s=r.get(t);s&&(s.callbacks=s.callbacks.filter(l=>l!==e.callback),s.callbacks.length||(s.observer?.disconnect(),r.delete(t))),e.observedElements=e.observedElements.filter(l=>l!==t)},T=e=>{const t=o.get(e);if(!t)return;[...t.observedElements].forEach(l=>{i(t,l)}),e.detachInvalidate(t.invalidationCallback),o.delete(e)};export{v as getEffectiveAriaLabelText,M as getAssociatedLabelForTexts,A as registerUI5Element,T as deregisterUI5Element,m as getAllAccessibleNameRefTexts};
//# sourceMappingURL=AriaLabelHelper.js.map

@@ -1,2 +0,2 @@

"use strict";let e=null;const u=(o,t)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=null,o()},t)};export default u;
"use strict";let e=null;const u=(t,o)=>{e&&clearTimeout(e),e=setTimeout(()=>{e=null,t()},o)};export default u;
//# sourceMappingURL=debounce.js.map

@@ -1,2 +0,2 @@

"use strict";let t=null,n=!1;const r=new Set,a=new Set,d=e=>{!e.dataTransfer||!(e.target instanceof HTMLElement)||(e.dataTransfer.dropEffect="move",e.dataTransfer.effectAllowed="move",a.has(e.target)||(t=e.target))},o=()=>{t=null},l=()=>{t=null},s=e=>{t=e},c=()=>t,m=()=>{n||(document.body.addEventListener("dragstart",d),document.body.addEventListener("dragend",o),document.body.addEventListener("drop",l))},g=()=>{document.body.removeEventListener("dragstart",d),document.body.removeEventListener("dragend",o),document.body.removeEventListener("drop",l),n=!1},E=e=>{r.add(e),n||m()},u=e=>{r.delete(e),r.size===0&&n&&g()},f=e=>(a.add(e),s),i=e=>{a.delete(e)},b={subscribe:E,unsubscribe:u,addSelfManagedArea:f,removeSelfManagedArea:i,getDraggedElement:c};export default b;
"use strict";let t=null,n=!1;const r=new Set,d=new Set,a=e=>{!e.dataTransfer||!(e.target instanceof HTMLElement)||d.has(e.target)||(t=e.target)},o=()=>{t=null},l=()=>{t=null},s=e=>{t=e},g=()=>t,c=()=>{n||(document.body.addEventListener("dragstart",a),document.body.addEventListener("dragend",o),document.body.addEventListener("drop",l))},m=()=>{document.body.removeEventListener("dragstart",a),document.body.removeEventListener("dragend",o),document.body.removeEventListener("drop",l),n=!1},E=e=>{r.add(e),n||c()},u=e=>{r.delete(e),r.size===0&&n&&m()},i=e=>(d.add(e),s),b=e=>{d.delete(e)},f={subscribe:E,unsubscribe:u,addSelfManagedArea:i,removeSelfManagedArea:b,getDraggedElement:g};export default f;
//# sourceMappingURL=DragRegistry.js.map

@@ -1,2 +0,2 @@

"use strict";import a from"./isElementHidden.js";const r=e=>{if(!e)return!1;const n=e.nodeName.toLowerCase();if(e.hasAttribute("data-sap-no-tab-ref")||a(e))return!1;const t=e.getAttribute("tabindex");return t!=null?parseInt(t)>=0:n==="a"||/input|select|textarea|button|object/.test(n)?!e.disabled:!1};export default r;
"use strict";import a from"./isElementHidden.js";const r=e=>{if(!e||e.hasAttribute("data-sap-no-tab-ref")||a(e))return!1;const t=e.getAttribute("tabindex");if(t!=null)return parseInt(t)>=0;const n=e.nodeName.toLowerCase();return n==="a"||/^(input|select|textarea|button|object)$/.test(n)?!e.disabled:!1};export default r;
//# sourceMappingURL=isElementTabbable.js.map

@@ -1,2 +0,2 @@

"use strict";import E from"./isElementTabbable.js";const T=t=>r([...t.children]),b=t=>{const n=r([...t.children]);return n.length?n[n.length-1]:null},r=(t,n)=>{const a=n||[];return t&&t.forEach(l=>{if(l.nodeType===Node.TEXT_NODE||l.nodeType===Node.COMMENT_NODE)return;let e=l;if(!e.hasAttribute("data-sap-no-tab-ref")){if(e.shadowRoot){const s=e.shadowRoot.children;e=Array.from(s).find(o=>o.tagName!=="STYLE")}e&&(E(e)&&a.push(e),e.tagName==="SLOT"?r(e.assignedNodes(),a):r([...e.children],a))}}),a};export{T as getTabbableElements,b as getLastTabbableElement};
"use strict";import o from"./isElementTabbable.js";const b=t=>a([...t.children]),E=t=>{const n=a([...t.children]);return n.length?n[n.length-1]:null},a=(t,n)=>{const l=n||[];return t&&t.forEach(r=>{if(r.nodeType===Node.TEXT_NODE||r.nodeType===Node.COMMENT_NODE)return;const e=r;if(!e.hasAttribute("data-sap-no-tab-ref"))if(o(e)&&l.push(e),e.tagName==="SLOT")a(e.assignedNodes(),l);else{const s=e.shadowRoot?e.shadowRoot.children:e.children;a([...s],l)}}),l};export{b as getTabbableElements,E as getLastTabbableElement};
//# sourceMappingURL=TabbableElements.js.map

@@ -1,2 +0,2 @@

import { TemplateResult } from "lit-html";
import type { TemplateResult } from "lit-html";
import type { Renderer } from "../UI5Element.js";

@@ -3,0 +3,0 @@ declare const effectiveHtml: (strings: TemplateStringsArray, ...values: Array<unknown>) => TemplateResult;

@@ -1,2 +0,2 @@

import UI5Element from "../UI5Element.js";
import type UI5Element from "../UI5Element.js";
/**

@@ -3,0 +3,0 @@ * Returns (and caches) a constructable style sheet for a web component class

@@ -1,2 +0,2 @@

import { PropertyValue } from "../UI5ElementMetadata.js";
import type { PropertyValue } from "../UI5ElementMetadata.js";
/**

@@ -3,0 +3,0 @@ * @class

@@ -1,2 +0,2 @@

import { PropertyValue } from "../UI5ElementMetadata.js";
import type { PropertyValue } from "../UI5ElementMetadata.js";
import DataType from "./DataType.js";

@@ -3,0 +3,0 @@ /**

@@ -1,2 +0,2 @@

import { PropertyValue } from "../UI5ElementMetadata.js";
import type { PropertyValue } from "../UI5ElementMetadata.js";
import DataType from "./DataType.js";

@@ -3,0 +3,0 @@ /**

import "@ui5/webcomponents-base/dist/ssr-dom.js";
import UI5ElementMetadata, { Slot, SlotValue, State, PropertyValue, Metadata } from "./UI5ElementMetadata.js";
import UI5ElementMetadata from "./UI5ElementMetadata.js";
import type { Slot, SlotValue, State, PropertyValue, Metadata } from "./UI5ElementMetadata.js";
import EventProvider from "./EventProvider.js";

@@ -4,0 +5,0 @@ import type { TemplateFunction, TemplateFunctionResult } from "./renderer/executeTemplate.js";

@@ -698,3 +698,6 @@ // eslint-disable-next-line import/no-extraneous-dependencies

const focusDomRef = this.getFocusDomRef();
if (focusDomRef && typeof focusDomRef.focus === "function") {
if (focusDomRef === this) {
HTMLElement.prototype.focus.call(this, focusOptions);
}
else if (focusDomRef && typeof focusDomRef.focus === "function") {
focusDomRef.focus(focusOptions);

@@ -701,0 +704,0 @@ }

@@ -1,2 +0,2 @@

import DataType from "./types/DataType.js";
import type DataType from "./types/DataType.js";
type SlotInvalidation = {

@@ -3,0 +3,0 @@ properties: boolean | Array<string>;

@@ -1,2 +0,2 @@

import UI5Element from "../UI5Element.js";
import type UI5Element from "../UI5Element.js";
type MutationCallback = () => void;

@@ -3,0 +3,0 @@ declare const getEffectiveAriaLabelText: (el: HTMLElement) => string | undefined;

@@ -9,4 +9,2 @@ let draggedElement = null;

}
e.dataTransfer.dropEffect = "move";
e.dataTransfer.effectAllowed = "move";
if (!selfManagedDragAreas.has(e.target)) {

@@ -13,0 +11,0 @@ draggedElement = e.target;

@@ -13,3 +13,2 @@ import isElementHidden from "./isElementHidden.js";

}
const nodeName = el.nodeName.toLowerCase();
if (el.hasAttribute("data-sap-no-tab-ref")) {

@@ -25,3 +24,4 @@ return false;

}
if (nodeName === "a" || /input|select|textarea|button|object/.test(nodeName)) {
const nodeName = el.nodeName.toLowerCase();
if (nodeName === "a" || /^(input|select|textarea|button|object)$/.test(nodeName)) {
return !el.disabled;

@@ -28,0 +28,0 @@ }

@@ -32,14 +32,6 @@ import isElementTabbable from "./isElementTabbable.js";

}
let currentElement = currentNode;
const currentElement = currentNode;
if (currentElement.hasAttribute("data-sap-no-tab-ref")) {
return;
}
if (currentElement.shadowRoot) {
// get the root node of the ShadowDom (1st none style tag)
const children = currentElement.shadowRoot.children;
currentElement = Array.from(children).find(node => node.tagName !== "STYLE");
}
if (!currentElement) {
return;
}
if (isElementTabbable(currentElement)) {

@@ -52,3 +44,4 @@ tabbableElements.push(currentElement);

else {
getTabbables([...currentElement.children], tabbableElements);
const children = currentElement.shadowRoot ? currentElement.shadowRoot.children : currentElement.children;
getTabbables([...children], tabbableElements);
}

@@ -55,0 +48,0 @@ });

{
"name": "@ui5/webcomponents-base",
"version": "2.0.0-rc.5",
"version": "2.0.0-rc.6",
"description": "UI5 Web Components: webcomponents.base",

@@ -54,3 +54,3 @@ "author": "SAP SE (https://www.sap.com)",

"@openui5/sap.ui.core": "1.120.5",
"@ui5/webcomponents-tools": "2.0.0-rc.5",
"@ui5/webcomponents-tools": "2.0.0-rc.6",
"chromedriver": "^125.0.0",

@@ -66,3 +66,3 @@ "clean-css": "^5.2.2",

},
"gitHead": "791653e253faae4847f026d022d0ddcd47a96666"
"gitHead": "19380fe3b367d021be5caf60e531ff50be91feef"
}

Sorry, the diff of this file is too big to display

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc