@compa11y/core 0.2.1 → 0.2.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @compa11y/core
2
2
 
3
+ ## 0.2.2
4
+
5
+ ### Minor Changes
6
+
7
+ - Tooltip added
8
+
3
9
  ## 0.2.1
4
10
 
5
11
  ### Minor Changes
@@ -1 +1 @@
1
- 'use strict';var chunkAQ6HEUSD_cjs=require('../chunk-AQ6HEUSD.cjs');require('../chunk-7BL2ABLF.cjs');Object.defineProperty(exports,"announce",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.b}});Object.defineProperty(exports,"announceAssertive",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.d}});Object.defineProperty(exports,"announceError",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.i}});Object.defineProperty(exports,"announcePolite",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.c}});Object.defineProperty(exports,"announceProgress",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.j}});Object.defineProperty(exports,"announceStatus",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.h}});Object.defineProperty(exports,"clearAnnouncements",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.e}});Object.defineProperty(exports,"createAnnouncer",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.g}});Object.defineProperty(exports,"initAnnouncer",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.a}});Object.defineProperty(exports,"queueAnnouncement",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.f}});
1
+ 'use strict';var chunkX5U6WLYD_cjs=require('../chunk-X5U6WLYD.cjs');require('../chunk-C7U5KZG2.cjs');Object.defineProperty(exports,"announce",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.b}});Object.defineProperty(exports,"announceAssertive",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.d}});Object.defineProperty(exports,"announceError",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.i}});Object.defineProperty(exports,"announcePolite",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.c}});Object.defineProperty(exports,"announceProgress",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.j}});Object.defineProperty(exports,"announceStatus",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.h}});Object.defineProperty(exports,"clearAnnouncements",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.e}});Object.defineProperty(exports,"createAnnouncer",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.g}});Object.defineProperty(exports,"initAnnouncer",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.a}});Object.defineProperty(exports,"queueAnnouncement",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.f}});
@@ -1 +1 @@
1
- export{b as announce,d as announceAssertive,i as announceError,c as announcePolite,j as announceProgress,h as announceStatus,e as clearAnnouncements,g as createAnnouncer,a as initAnnouncer,f as queueAnnouncement}from'../chunk-ZAQMM5TA.js';import'../chunk-C3VZQUKG.js';
1
+ export{b as announce,d as announceAssertive,i as announceError,c as announcePolite,j as announceProgress,h as announceStatus,e as clearAnnouncements,g as createAnnouncer,a as initAnnouncer,f as queueAnnouncement}from'../chunk-RW6UYIXK.js';import'../chunk-25OQO77R.js';
@@ -1 +1 @@
1
- 'use strict';var chunkKQUAJKTG_cjs=require('../chunk-KQUAJKTG.cjs');Object.defineProperty(exports,"aria",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.a}});Object.defineProperty(exports,"buildAriaProps",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.b}});Object.defineProperty(exports,"hasAccessibleName",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.d}});Object.defineProperty(exports,"mergeAriaIds",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.c}});
1
+ 'use strict';require('../chunk-QSOIUQG6.cjs');var chunkS5TRVOSB_cjs=require('../chunk-S5TRVOSB.cjs');Object.defineProperty(exports,"aria",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.a}});Object.defineProperty(exports,"buildAriaProps",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.b}});Object.defineProperty(exports,"hasAccessibleName",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.d}});Object.defineProperty(exports,"mergeAriaIds",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.c}});
@@ -1 +1 @@
1
- export{a as aria,b as buildAriaProps,d as hasAccessibleName,c as mergeAriaIds}from'../chunk-TGXWODB3.js';
1
+ import'../chunk-B3F6LTF6.js';export{a as aria,b as buildAriaProps,d as hasAccessibleName,c as mergeAriaIds}from'../chunk-5LRBCHHZ.js';
@@ -1 +1 @@
1
- function e(){return typeof window<"u"&&typeof document<"u"}function s(){return e()?/Mac|iPod|iPhone|iPad/.test(navigator.platform):false}function c(){return e()?/iPod|iPhone|iPad/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1:false}function d(){return e()?/Android/.test(navigator.userAgent):false}function f(){return e()?/Win/.test(navigator.platform):false}function u(){return e()?"ontouchstart"in window||navigator.maxTouchPoints>0:false}function l(){return e()?window.matchMedia("(prefers-reduced-motion: reduce)").matches:false}function m(){return e()?window.matchMedia("(prefers-contrast: more)").matches||window.matchMedia("(-ms-high-contrast: active)").matches:false}function h(){return e()?window.matchMedia("(prefers-color-scheme: dark)").matches:false}function p(){if(!e())return {possibleScreenReader:false,forcedColors:false};let n=window.matchMedia("(forced-colors: active)").matches;return {possibleScreenReader:n,forcedColors:n}}function v(n,o){if(!e())return ()=>{};let r=window.matchMedia(n);if(o(r.matches),r.addEventListener){let a=i=>o(i.matches);return r.addEventListener("change",a),()=>r.removeEventListener("change",a)}let t=()=>o(r.matches);return r.addListener(t),()=>r.removeListener(t)}export{e as a,s as b,c,d,f as e,u as f,l as g,m as h,h as i,p as j,v as k};
1
+ function e(){return typeof window<"u"&&typeof document<"u"}function s(){return e()?/Mac|iPod|iPhone|iPad/.test(navigator.platform):false}function c(){return e()?/iPod|iPhone|iPad/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1:false}function d(){return e()?/Android/.test(navigator.userAgent):false}function f(){return e()?/Win/.test(navigator.platform):false}function u(){return e()?"ontouchstart"in window||navigator.maxTouchPoints>0:false}function l(){return e()?window.matchMedia("(prefers-reduced-motion: reduce)").matches:false}function m(){return e()?window.matchMedia("(prefers-contrast: more)").matches||window.matchMedia("(-ms-high-contrast: active)").matches:false}function h(){return e()?window.matchMedia("(prefers-color-scheme: dark)").matches:false}function p(){return e()?window.matchMedia("(pointer: coarse)").matches:false}function w(){return e()?window.matchMedia("(pointer: fine)").matches:false}function v(){if(!e())return {possibleScreenReader:false,forcedColors:false};let n=window.matchMedia("(forced-colors: active)").matches;return {possibleScreenReader:n,forcedColors:n}}function b(n,o){if(!e())return ()=>{};let r=window.matchMedia(n);if(o(r.matches),r.addEventListener){let i=a=>o(a.matches);return r.addEventListener("change",i),()=>r.removeEventListener("change",i)}let t=()=>o(r.matches);return r.addListener(t),()=>r.removeListener(t)}export{e as a,s as b,c,d,f as e,u as f,l as g,m as h,h as i,p as j,w as k,v as l,b as m};
@@ -1 +1 @@
1
- var r={hide(e){e.setAttribute("aria-hidden","true");},show(e){e.removeAttribute("aria-hidden");},setExpanded(e,t){e.setAttribute("aria-expanded",String(t));},setSelected(e,t){e.setAttribute("aria-selected",String(t));},setChecked(e,t){e.setAttribute("aria-checked",String(t));},setPressed(e,t){e.setAttribute("aria-pressed",String(t));},setDisabled(e,t){e.setAttribute("aria-disabled",String(t));},setBusy(e,t){e.setAttribute("aria-busy",String(t));},setCurrent(e,t){t==="false"?e.removeAttribute("aria-current"):e.setAttribute("aria-current",t);},setInvalid(e,t){t===false?e.removeAttribute("aria-invalid"):e.setAttribute("aria-invalid",String(t));},setLabel(e,t){t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label");},setLabelledBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-labelledby",i):e.removeAttribute("aria-labelledby");},setDescribedBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-describedby",i):e.removeAttribute("aria-describedby");},setControls(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-controls",i):e.removeAttribute("aria-controls");},setOwns(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-owns",i):e.removeAttribute("aria-owns");},setActiveDescendant(e,t){t?e.setAttribute("aria-activedescendant",t):e.removeAttribute("aria-activedescendant");},setHasPopup(e,t){t===false?e.removeAttribute("aria-haspopup"):e.setAttribute("aria-haspopup",String(t));},setLevel(e,t){e.setAttribute("aria-level",String(t));},setPosition(e,t,i){e.setAttribute("aria-posinset",String(t)),e.setAttribute("aria-setsize",String(i));},setValue(e,t){t.min!==void 0&&e.setAttribute("aria-valuemin",String(t.min)),t.max!==void 0&&e.setAttribute("aria-valuemax",String(t.max)),t.now!==void 0&&e.setAttribute("aria-valuenow",String(t.now)),t.text!==void 0&&e.setAttribute("aria-valuetext",t.text);},setRole(e,t){t?e.setAttribute("role",t):e.removeAttribute("role");},setModal(e,t){t?e.setAttribute("aria-modal","true"):e.removeAttribute("aria-modal");},setOrientation(e,t){e.setAttribute("aria-orientation",t);},setRequired(e,t){e.setAttribute("aria-required",String(t));},setReadOnly(e,t){e.setAttribute("aria-readonly",String(t));},setAutocomplete(e,t){e.setAttribute("aria-autocomplete",t);},setMultiSelectable(e,t){e.setAttribute("aria-multiselectable",String(t));},setSort(e,t){e.setAttribute("aria-sort",t);}};function l(e){let t={};return e.label&&(t["aria-label"]=e.label),e.labelledBy&&(t["aria-labelledby"]=Array.isArray(e.labelledBy)?e.labelledBy.join(" "):e.labelledBy),e.describedBy&&(t["aria-describedby"]=Array.isArray(e.describedBy)?e.describedBy.join(" "):e.describedBy),e.controls&&(t["aria-controls"]=Array.isArray(e.controls)?e.controls.join(" "):e.controls),e.owns&&(t["aria-owns"]=Array.isArray(e.owns)?e.owns.join(" "):e.owns),e.expanded!==void 0&&(t["aria-expanded"]=String(e.expanded)),e.selected!==void 0&&(t["aria-selected"]=String(e.selected)),e.checked!==void 0&&(t["aria-checked"]=String(e.checked)),e.pressed!==void 0&&(t["aria-pressed"]=String(e.pressed)),e.disabled!==void 0&&(t["aria-disabled"]=String(e.disabled)),e.hidden!==void 0&&(t["aria-hidden"]=String(e.hidden)),e.modal!==void 0&&(t["aria-modal"]=String(e.modal)),e.busy!==void 0&&(t["aria-busy"]=String(e.busy)),e.current&&(t["aria-current"]=e.current),e.invalid!==void 0&&(t["aria-invalid"]=String(e.invalid)),e.hasPopup!==void 0&&(t["aria-haspopup"]=String(e.hasPopup)),e.activeDescendant&&(t["aria-activedescendant"]=e.activeDescendant),e.level!==void 0&&(t["aria-level"]=String(e.level)),e.posInSet!==void 0&&(t["aria-posinset"]=String(e.posInSet)),e.setSize!==void 0&&(t["aria-setsize"]=String(e.setSize)),e.valueMin!==void 0&&(t["aria-valuemin"]=String(e.valueMin)),e.valueMax!==void 0&&(t["aria-valuemax"]=String(e.valueMax)),e.valueNow!==void 0&&(t["aria-valuenow"]=String(e.valueNow)),e.valueText&&(t["aria-valuetext"]=e.valueText),e.orientation&&(t["aria-orientation"]=e.orientation),e.required!==void 0&&(t["aria-required"]=String(e.required)),e.readOnly!==void 0&&(t["aria-readonly"]=String(e.readOnly)),e.autocomplete&&(t["aria-autocomplete"]=e.autocomplete),e.multiSelectable!==void 0&&(t["aria-multiselectable"]=String(e.multiSelectable)),e.sort&&(t["aria-sort"]=e.sort),e.role&&(t.role=e.role),t}function d(...e){let t=e.filter(Boolean);return t.length>0?t.join(" "):void 0}function u(e){if(e.getAttribute("aria-label"))return true;let t=e.getAttribute("aria-labelledby");return !!(t&&t.split(" ").some(n=>{let a=document.getElementById(n);return a&&a.textContent?.trim()})||e.textContent?.trim()||e.getAttribute("title")||"labels"in e&&e.labels?.length||e.tagName==="IMG"&&e.getAttribute("alt"))}export{r as a,l as b,d as c,u as d};
1
+ var l={hide(e){e.setAttribute("aria-hidden","true");},show(e){e.removeAttribute("aria-hidden");},setExpanded(e,t){e.setAttribute("aria-expanded",String(t));},setSelected(e,t){e.setAttribute("aria-selected",String(t));},setChecked(e,t){e.setAttribute("aria-checked",String(t));},setPressed(e,t){e.setAttribute("aria-pressed",String(t));},setDisabled(e,t){e.setAttribute("aria-disabled",String(t));},setBusy(e,t){e.setAttribute("aria-busy",String(t));},setCurrent(e,t){t==="false"?e.removeAttribute("aria-current"):e.setAttribute("aria-current",t);},setInvalid(e,t){t===false?e.removeAttribute("aria-invalid"):e.setAttribute("aria-invalid",String(t));},setLabel(e,t){t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label");},setLabelledBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-labelledby",i):e.removeAttribute("aria-labelledby");},setDescribedBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-describedby",i):e.removeAttribute("aria-describedby");},setControls(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-controls",i):e.removeAttribute("aria-controls");},setOwns(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-owns",i):e.removeAttribute("aria-owns");},setActiveDescendant(e,t){t?e.setAttribute("aria-activedescendant",t):e.removeAttribute("aria-activedescendant");},setHasPopup(e,t){t===false?e.removeAttribute("aria-haspopup"):e.setAttribute("aria-haspopup",String(t));},setLevel(e,t){e.setAttribute("aria-level",String(t));},setPosition(e,t,i){e.setAttribute("aria-posinset",String(t)),e.setAttribute("aria-setsize",String(i));},setValue(e,t){t.min!==void 0&&e.setAttribute("aria-valuemin",String(t.min)),t.max!==void 0&&e.setAttribute("aria-valuemax",String(t.max)),t.now!==void 0&&e.setAttribute("aria-valuenow",String(t.now)),t.text!==void 0&&e.setAttribute("aria-valuetext",t.text);},setRole(e,t){t?e.setAttribute("role",t):e.removeAttribute("role");},setModal(e,t){t?e.setAttribute("aria-modal","true"):e.removeAttribute("aria-modal");},setOrientation(e,t){e.setAttribute("aria-orientation",t);},setRequired(e,t){e.setAttribute("aria-required",String(t));},setReadOnly(e,t){e.setAttribute("aria-readonly",String(t));},setAutocomplete(e,t){e.setAttribute("aria-autocomplete",t);},setMultiSelectable(e,t){e.setAttribute("aria-multiselectable",String(t));},setSort(e,t){e.setAttribute("aria-sort",t);}};function d(e){let t={};return e.label&&(t["aria-label"]=e.label),e.labelledBy&&(t["aria-labelledby"]=Array.isArray(e.labelledBy)?e.labelledBy.join(" "):e.labelledBy),e.describedBy&&(t["aria-describedby"]=Array.isArray(e.describedBy)?e.describedBy.join(" "):e.describedBy),e.controls&&(t["aria-controls"]=Array.isArray(e.controls)?e.controls.join(" "):e.controls),e.owns&&(t["aria-owns"]=Array.isArray(e.owns)?e.owns.join(" "):e.owns),e.expanded!==void 0&&(t["aria-expanded"]=String(e.expanded)),e.selected!==void 0&&(t["aria-selected"]=String(e.selected)),e.checked!==void 0&&(t["aria-checked"]=String(e.checked)),e.pressed!==void 0&&(t["aria-pressed"]=String(e.pressed)),e.disabled!==void 0&&(t["aria-disabled"]=String(e.disabled)),e.hidden!==void 0&&(t["aria-hidden"]=String(e.hidden)),e.modal!==void 0&&(t["aria-modal"]=String(e.modal)),e.busy!==void 0&&(t["aria-busy"]=String(e.busy)),e.current&&(t["aria-current"]=e.current),e.invalid!==void 0&&(t["aria-invalid"]=String(e.invalid)),e.hasPopup!==void 0&&(t["aria-haspopup"]=String(e.hasPopup)),e.activeDescendant&&(t["aria-activedescendant"]=e.activeDescendant),e.level!==void 0&&(t["aria-level"]=String(e.level)),e.posInSet!==void 0&&(t["aria-posinset"]=String(e.posInSet)),e.setSize!==void 0&&(t["aria-setsize"]=String(e.setSize)),e.valueMin!==void 0&&(t["aria-valuemin"]=String(e.valueMin)),e.valueMax!==void 0&&(t["aria-valuemax"]=String(e.valueMax)),e.valueNow!==void 0&&(t["aria-valuenow"]=String(e.valueNow)),e.valueText&&(t["aria-valuetext"]=e.valueText),e.orientation&&(t["aria-orientation"]=e.orientation),e.required!==void 0&&(t["aria-required"]=String(e.required)),e.readOnly!==void 0&&(t["aria-readonly"]=String(e.readOnly)),e.autocomplete&&(t["aria-autocomplete"]=e.autocomplete),e.multiSelectable!==void 0&&(t["aria-multiselectable"]=String(e.multiSelectable)),e.sort&&(t["aria-sort"]=e.sort),e.role&&(t.role=e.role),t}function u(...e){let t=e.filter(Boolean);return t.length>0?t.join(" "):void 0}function o(e){if(e.getAttribute("aria-label"))return true;let t=e.getAttribute("aria-labelledby");return !!(t&&t.split(" ").some(n=>{let a=document.getElementById(n);return a&&a.textContent?.trim()})||e.textContent?.trim()||e.getAttribute("title")||"labels"in e&&e.labels?.length||e.tagName==="IMG"&&e.getAttribute("alt"))}export{l as a,d as b,u as c,o as d};
@@ -0,0 +1 @@
1
+ 'use strict';function f(e){let t=e.key;switch(t){case " ":return "Space";case "Esc":return "Escape";case "Left":return "ArrowLeft";case "Right":return "ArrowRight";case "Up":return "ArrowUp";case "Down":return "ArrowDown";default:return t}}function g(e){let t=[];e.ctrlKey&&t.push("Ctrl"),e.altKey&&t.push("Alt"),e.shiftKey&&t.push("Shift"),e.metaKey&&t.push("Meta");let i=f(e);return ["Control","Alt","Shift","Meta"].includes(i)||t.push(i),t.join("+")}function b(e={},t={}){let{preventDefault:i=true,stopPropagation:d=true,targetSelector:n}=t,r=new Map(Object.entries(e)),a=null;function l(o){if(n&&!o.target.matches(n))return;let y=g(o),c=r.get(y);if(!c){let u=f(o);c=r.get(u);}c&&c(o)!==false&&(i&&o.preventDefault(),d&&o.stopPropagation());}function p(o){a&&s(),a=o,o.addEventListener("keydown",l);}function s(){a&&(a.removeEventListener("keydown",l),a=null);}function m(o,y){r.set(o,y);}function v(o){r.delete(o);}function h(){s(),r.clear();}return {attach:p,detach:s,on:m,off:v,destroy:h}}var K={menu:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),Enter:()=>e.onEnter?.(),Space:()=>e.onEnter?.(),Escape:()=>e.onEscape?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),tabs:e=>({ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),dialog:e=>({Escape:()=>e.onEscape?.()}),grid:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.(),"Ctrl+Home":()=>e.onCtrlHome?.(),"Ctrl+End":()=>e.onCtrlEnd?.()})};function E(e,t={}){let{timeout:i=500}=t,d="",n=null;function r(){d="",n&&(clearTimeout(n),n=null);}function a(l){return l.length!==1||l===" "?null:(n&&clearTimeout(n),d+=l.toLowerCase(),n=setTimeout(r,i),e.find(s=>s.toLowerCase().startsWith(d))??null)}return {type:a,reset:r,getSearch:()=>d}}exports.a=f;exports.b=g;exports.c=b;exports.d=K;exports.e=E;
File without changes
@@ -0,0 +1 @@
1
+ 'use strict';function e(){return typeof window<"u"&&typeof document<"u"}function s(){return e()?/Mac|iPod|iPhone|iPad/.test(navigator.platform):false}function c(){return e()?/iPod|iPhone|iPad/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1:false}function d(){return e()?/Android/.test(navigator.userAgent):false}function f(){return e()?/Win/.test(navigator.platform):false}function u(){return e()?"ontouchstart"in window||navigator.maxTouchPoints>0:false}function l(){return e()?window.matchMedia("(prefers-reduced-motion: reduce)").matches:false}function m(){return e()?window.matchMedia("(prefers-contrast: more)").matches||window.matchMedia("(-ms-high-contrast: active)").matches:false}function h(){return e()?window.matchMedia("(prefers-color-scheme: dark)").matches:false}function p(){return e()?window.matchMedia("(pointer: coarse)").matches:false}function w(){return e()?window.matchMedia("(pointer: fine)").matches:false}function v(){if(!e())return {possibleScreenReader:false,forcedColors:false};let n=window.matchMedia("(forced-colors: active)").matches;return {possibleScreenReader:n,forcedColors:n}}function b(n,o){if(!e())return ()=>{};let r=window.matchMedia(n);if(o(r.matches),r.addEventListener){let i=a=>o(a.matches);return r.addEventListener("change",i),()=>r.removeEventListener("change",i)}let t=()=>o(r.matches);return r.addListener(t),()=>r.removeListener(t)}exports.a=e;exports.b=s;exports.c=c;exports.d=d;exports.e=f;exports.f=u;exports.g=l;exports.h=m;exports.i=h;exports.j=p;exports.k=w;exports.l=v;exports.m=b;
@@ -0,0 +1,3 @@
1
+ 'use strict';var chunkC7U5KZG2_cjs=require('./chunk-C7U5KZG2.cjs'),chunkS5TRVOSB_cjs=require('./chunk-S5TRVOSB.cjs');var N=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]',"audio[controls]","video[controls]","details > summary:first-of-type","iframe"].join(","),$=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])','[contenteditable="true"]:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','details > summary:first-of-type:not([tabindex="-1"])','iframe:not([tabindex="-1"])'].join(",");function j(e){if(!(e instanceof HTMLElement)||e.hidden||e.style.display==="none"||e.style.visibility==="hidden")return false;let t=window.getComputedStyle(e);return !(t.display==="none"||t.visibility==="hidden"||!e.isConnected)}function q(e){return !(!(e instanceof HTMLElement)||!j(e)||!e.matches(N)||e.closest("[inert]"))}function O(e){return !q(e)||e.tabIndex<0?false:e.matches($)}function pe(e){return Array.from(e.querySelectorAll(N)).filter(q)}function h(e){return Array.from(e.querySelectorAll($)).filter(O).sort((o,r)=>{let i=Math.max(0,o.tabIndex),u=Math.max(0,r.tabIndex);return i===0&&u===0?0:i===0?1:u===0?-1:i-u})}function S(e){return h(e)[0]??null}function me(e){let t=h(e);return t[t.length-1]??null}function U(e){let t=document.activeElement;return t!==null&&e.contains(t)}function B(e,t,n=true){let o=h(e),r=o.indexOf(t);if(r===-1)return o[0]??null;let i=r+1;return i<o.length?o[i]:n?o[0]??null:null}function _(e,t,n=true){let o=h(e),r=o.indexOf(t);if(r===-1)return o[o.length-1]??null;let i=r-1;return i>=0?o[i]:n?o[o.length-1]??null:null}function ge(e,t){return t.contains(e)}function z(e,t=document.body){return e?typeof e=="string"?t.querySelector(e):typeof e=="function"?e():e:null}var K=null,C=new Set;function Y(){return typeof process<"u"&&process.env?.NODE_ENV!=="production"}function xe(e){K=e;}function J(e){return `${e.component}:${e.message}`}function x(e){if(!Y())return;let t=J(e);if(C.has(t))return;if(C.add(t),K){K(e);return}let n=`[compa11y/${e.component}]`,o=Q(e.type),r=e.suggestion?`${e.message}
2
+
3
+ \u{1F4A1} Suggestion: ${e.suggestion}`:e.message;switch(e.type){case "error":console.error(`%c${n}%c ${r}`,o,"");break;case "warning":console.warn(`%c${n}%c ${r}`,o,"");break;case "info":console.info(`%c${n}%c ${r}`,o,"");break}e.element&&console.log("Element:",e.element);}function Q(e){switch(e){case "error":return "background: #ff5555; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "warning":return "background: #ffaa00; color: black; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "info":return "background: #5555ff; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;"}}function he(){C.clear();}var I={accessibleLabel(e,t,n="aria-label"){e&&(chunkS5TRVOSB_cjs.d(e)||x({type:"error",component:t,message:"Missing accessible label. Screen reader users will not be able to understand this element.",suggestion:`Add ${n}, aria-labelledby, or visible text content.`,element:e}));},requiredProp(e,t,n){(e==null||e==="")&&x({type:"error",component:n,message:`Missing required prop "${t}".`,suggestion:`Provide a value for the "${t}" prop.`});},validRole(e,t,n){if(!e)return;new Set(["alert","alertdialog","application","article","banner","button","cell","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","navigation","none","note","option","presentation","progressbar","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"]).has(e)||x({type:"warning",component:t,message:`Invalid ARIA role "${e}".`,suggestion:"Use a valid ARIA role from the WAI-ARIA specification.",element:n});},keyboardAccessible(e,t,n){if(e&&n.onClick&&!n.onKeyDown){let o=e.tagName.toLowerCase(),r=e.getAttribute("role");if(["button","a","input","select","textarea"].includes(o))return;r&&["button","link","menuitem","option","tab"].includes(r)&&x({type:"warning",component:t,message:"Element has onClick but no onKeyDown handler.",suggestion:"Add keyboard event handling for Enter and Space keys.",element:e});}},tabIndex(e,t,n){e!==void 0&&e>0&&x({type:"warning",component:t,message:`Positive tabIndex (${e}) disrupts natural tab order.`,suggestion:"Use tabIndex={0} or tabIndex={-1} instead. Rely on DOM order for tab sequence.",element:n});},dialogAutoFocus(e,t){e||x({type:"info",component:t,message:"No initial focus element specified for dialog.",suggestion:"Consider setting initialFocus to guide keyboard users."});},formLabel(e,t,n){if(!e)return;t||e.getAttribute("aria-label")||e.getAttribute("aria-labelledby")||e.labels?.length||x({type:"error",component:n,message:"Form input is missing an accessible label.",suggestion:"Add a <label>, aria-label, or aria-labelledby.",element:e});},imageAlt(e,t){if(!e||e.tagName!=="IMG")return;let n=e.getAttribute("alt"),o=e.getAttribute("role");n===null&&o!=="presentation"&&o!=="none"&&x({type:"error",component:t,message:"Image is missing alt attribute.",suggestion:'Add alt="" for decorative images or descriptive alt text for meaningful images.',element:e});}};function D(e){return {error:(t,n,o)=>x({type:"error",component:e,message:t,suggestion:n,element:o}),warning:(t,n,o)=>x({type:"warning",component:e,message:t,suggestion:n,element:o}),info:(t,n,o)=>x({type:"info",component:e,message:t,suggestion:n,element:o}),checks:{accessibleLabel:(t,n)=>I.accessibleLabel(t,e,n),requiredProp:(t,n)=>I.requiredProp(t,n,e),keyboardAccessible:(t,n)=>I.keyboardAccessible(t,e,n),tabIndex:(t,n)=>I.tabIndex(t,e,n)}}}var y=[],X=D("FocusTrap");function Z(e,t={}){let{initialFocus:n,returnFocus:o=true,clickOutsideDeactivates:r=false,escapeDeactivates:i=true,onDeactivate:u,onEscapeFocus:l}=t,s=false,b=false,d=null;function T(c){b||!s||(c.key==="Tab"?F(c):c.key==="Escape"&&i&&(c.preventDefault(),c.stopPropagation(),g()));}function F(c){let v=h(e);if(v.length===0){c.preventDefault();return}let k=v[0],M=v[v.length-1],A=document.activeElement;c.shiftKey?(A===k||!e.contains(A))&&(c.preventDefault(),M.focus()):(A===M||!e.contains(A))&&(c.preventDefault(),k.focus());}function m(c){if(b||!s)return;let v=c.target;e.contains(v)||(l?.(v),S(e)?.focus());}function f(c){if(b||!s)return;let v=c.target;r&&!e.contains(v)&&g();}function p(){if(!s){d=document.activeElement,y.push(R);for(let c=0;c<y.length-1;c++)y[c].pause();document.addEventListener("keydown",T,true),document.addEventListener("focusin",m,true),document.addEventListener("click",f,true),s=true,requestAnimationFrame(()=>{if(!s)return;let c=z(n,e);if(c)c.focus();else {let v=S(e);v?v.focus():(X.warning("No focusable elements found inside the focus trap container. The container itself will be focused.","Add focusable elements (buttons, inputs, links) inside the trap container.",e),e.setAttribute("tabindex","-1"),e.focus());}});}}function a(c){if(!s)return;document.removeEventListener("keydown",T,true),document.removeEventListener("focusin",m,true),document.removeEventListener("click",f,true),s=false,b=false;let v=y.indexOf(R);if(v>-1&&y.splice(v,1),y[y.length-1]?.unpause(),o&&d){let M=typeof o=="boolean"?d:o;requestAnimationFrame(()=>{M&&"focus"in M&&M.focus();});}c&&u?.();}function g(){a(true);}function L(){a(false);}function H(){!s||b||(b=true);}function w(){!s||!b||(b=false,U(e)||S(e)?.focus());}let R={activate:p,deactivate:g,destroy:L,pause:H,unpause:w,isActive:()=>s,isPaused:()=>b};return R}function ee(){return y[y.length-1]??null}function te(){return y.length>0}var E={hadKeyboardEvent:true,isPointerInput:false,lastFocusSource:"unknown"},P=false,ne=new Set(["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"," ","Home","End","PageUp","PageDown","Escape"]);function oe(){if(!chunkC7U5KZG2_cjs.a()||P)return ()=>{};P=true;function e(i){ne.has(i.key)&&(E.hadKeyboardEvent=true,E.isPointerInput=false,E.lastFocusSource="keyboard");}function t(i){E.isPointerInput=true,E.hadKeyboardEvent=false,E.lastFocusSource="pointerType"in i&&i.pointerType==="touch"?"touch":"mouse";}function n(i){let u=i.target;u instanceof HTMLElement&&(E.hadKeyboardEvent||re(u))&&(u.dataset.compa11yFocusVisible="true");}function o(i){let u=i.target;u instanceof HTMLElement&&delete u.dataset.compa11yFocusVisible;}function r(){document.visibilityState==="hidden"&&(E.hadKeyboardEvent=true);}return document.addEventListener("keydown",e,true),document.addEventListener("mousedown",t,true),document.addEventListener("pointerdown",t,true),document.addEventListener("focus",n,true),document.addEventListener("blur",o,true),document.addEventListener("visibilitychange",r,true),()=>{document.removeEventListener("keydown",e,true),document.removeEventListener("mousedown",t,true),document.removeEventListener("pointerdown",t,true),document.removeEventListener("focus",n,true),document.removeEventListener("blur",o,true),document.removeEventListener("visibilitychange",r,true),P=false;}}function re(e){let t=e.tagName.toLowerCase(),n=e.getAttribute("type")?.toLowerCase();return !!(t==="input"&&(!n||n==="text"||n==="email"||n==="password"||n==="search"||n==="tel"||n==="url"||n==="number")||t==="textarea"||e.isContentEditable)}function ie(){return E.hadKeyboardEvent}function se(e){return e.dataset.compa11yFocusVisible==="true"}function ue(){return E.lastFocusSource}function ae(e,t){t?e.dataset.compa11yFocusVisible="true":delete e.dataset.compa11yFocusVisible;}function le(e,t){E.hadKeyboardEvent=true,E.lastFocusSource="keyboard",e.focus(t);}function ce(e,t={}){let{contain:n=false,restoreFocus:o=false,autoFocus:r=false}=t,i=null,u=false;o&&(i=document.activeElement);function l(){return u?[]:h(e)}function s(){let a=document.activeElement;return a&&e.contains(a)?a:null}function b(){if(u)return;l()[0]?.focus();}function d(){if(u)return;let a=l();a[a.length-1]?.focus();}function T({wrap:a=true}={}){if(u)return;let g=s();if(!g){b();return}B(e,g,a)?.focus();}function F({wrap:a=true}={}){if(u)return;let g=s();if(!g){d();return}_(e,g,a)?.focus();}function m(a){if(u)return;l()[a]?.focus();}function f(a){if(!(u||!n)&&a.key==="Tab"){let g=l();if(g.length===0){a.preventDefault();return}let L=g[0],H=g[g.length-1],w=s();a.shiftKey&&w===L?(a.preventDefault(),H.focus()):!a.shiftKey&&w===H&&(a.preventDefault(),L.focus());}}function p(){u||(u=true,document.removeEventListener("keydown",f,true),o&&i&&i.focus());}return n&&document.addEventListener("keydown",f,true),r&&requestAnimationFrame(()=>{u||b();}),{focusFirst:b,focusLast:d,focusNext:T,focusPrevious:F,focusAt:m,getFocused:s,getElements:l,destroy:p}}var de=D("RovingTabindex");function fe(e,t,n={}){let{initialIndex:o=0,orientation:r="both",wrap:i=true,onSelectionChange:u}=n,l=[],s=o;function b(){l=Array.from(e.querySelectorAll(t)),l.length===0&&de.warning(`No elements matching "${t}" found in the container. Roving tabindex has nothing to manage.`,"Ensure the container has child elements matching the selector.",e),l.forEach((m,f)=>{m.setAttribute("tabindex",f===s?"0":"-1");});}function d(m){if(l.length===0)return;let f=m;f<0?f=i?l.length-1:0:f>=l.length&&(f=i?0:l.length-1);let p=l[s],a=l[f];p&&p.setAttribute("tabindex","-1"),a&&(a.setAttribute("tabindex","0"),a.focus(),u?.(f,a)),s=f;}function T(m){let f=m.target;if(!l.includes(f))return;let p=false;switch(m.key){case "ArrowRight":(r==="horizontal"||r==="both")&&(d(s+1),p=true);break;case "ArrowLeft":(r==="horizontal"||r==="both")&&(d(s-1),p=true);break;case "ArrowDown":(r==="vertical"||r==="both")&&(d(s+1),p=true);break;case "ArrowUp":(r==="vertical"||r==="both")&&(d(s-1),p=true);break;case "Home":d(0),p=true;break;case "End":d(l.length-1),p=true;break}p&&(m.preventDefault(),m.stopPropagation());}function F(m){let f=m.target,p=l.indexOf(f);if(p!==-1&&p!==s){let a=l[s];a&&a.setAttribute("tabindex","-1"),f.setAttribute("tabindex","0"),s=p;}}return b(),e.addEventListener("keydown",T),e.addEventListener("focusin",F),{next:()=>d(s+1),previous:()=>d(s-1),first:()=>d(0),last:()=>d(l.length-1),goto:d,getIndex:()=>s,update:b,destroy:()=>{e.removeEventListener("keydown",T),e.removeEventListener("focusin",F);}}}function G(e,t={}){let{scope:n=e.parentElement??document.body,prefer:o="previous"}=t,r=h(n),i=r.indexOf(e);i===-1&&(i=r.findIndex(d=>e.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_FOLLOWING),i===-1&&(i=r.length));let u=i-1,l=i+1,s=u>=0&&r[u]!==e?r[u]:null,b=l<r.length&&r[l]!==e?r[l]:null;return o==="previous"?s??b:b??s}function be(e){let t=e??null;function n(i){t=i??document.activeElement??null;}function o(i={}){let{fallback:u,prefer:l="previous"}=i;if(!t){u?.focus();return}if(t.isConnected&&O(t)){t.focus(),t=null;return}if(t.isConnected){let s=G(t,{prefer:l});if(s){s.focus(),t=null;return}}u&&u.focus(),t=null;}function r(){t=null;}return {get element(){return t},save:n,return:o,clear:r}}exports.A=ae;exports.B=le;exports.C=ce;exports.D=fe;exports.E=G;exports.F=be;exports.a=N;exports.b=$;exports.c=j;exports.d=q;exports.e=O;exports.f=pe;exports.g=h;exports.h=S;exports.i=me;exports.j=U;exports.k=B;exports.l=_;exports.m=ge;exports.n=z;exports.o=xe;exports.p=x;exports.q=he;exports.r=I;exports.s=D;exports.t=Z;exports.u=ee;exports.v=te;exports.w=oe;exports.x=ie;exports.y=se;exports.z=ue;
@@ -0,0 +1 @@
1
+ 'use strict';
@@ -0,0 +1 @@
1
+ import {a as a$1}from'./chunk-25OQO77R.js';var o=null,i=null,m=false,c=[],r=null,g=null,v=0,S=500;function T(){return {position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0"}}function y(e){let n=document.createElement("div");n.setAttribute("role","status"),n.setAttribute("aria-live",e),n.setAttribute("aria-atomic","true"),n.setAttribute("aria-relevant","additions text"),n.id=`compa11y-announcer-${e}`;let t=T();return Object.assign(n.style,t),document.body.appendChild(n),{element:n,politeness:e}}function L(){return !a$1()||m?()=>{}:(m=true,o=y("polite"),i=y("assertive"),()=>{o&&(o.element.remove(),o=null),i&&(i.element.remove(),i=null),r&&(clearTimeout(r),r=null),c=[],g=null,v=0,m=false;})}function h(){!m&&a$1()&&L();}function A(e){e.element.textContent="";}function a(e,n={}){if(!a$1())return;let{politeness:t="polite",delay:s=0,clearPrevious:l=false,timeout:x=7e3}=n;h();let b=Date.now();if(e===g&&b-v<S)return;g=e,v=b;let u=t==="assertive"?i:o;if(!u)return;let O=()=>{l&&A(u),u.element.textContent="",requestAnimationFrame(()=>{u.element.textContent=e,x>0&&setTimeout(()=>{u.element.textContent===e&&(u.element.textContent="");},x);});};s>0?setTimeout(O,s):O();}function f(e,n){a(e,{...n,politeness:"polite"});}function d(e,n){a(e,{...n,politeness:"assertive"});}function P(){o&&A(o),i&&A(i);}function R(e,n={}){let{debounce:t=150,...s}=n;c.push({message:e,options:s}),r&&clearTimeout(r),r=setTimeout(()=>{let l=c[c.length-1];l&&a(l.message,l.options),c=[],r=null;},t);}function w(e={}){return {announce:(n,t)=>a(n,{...e,...t}),polite:(n,t)=>f(n,{...e,...t}),assertive:(n,t)=>d(n,{...e,...t}),queue:(n,t)=>R(n,{...e,...t}),clear:P}}function C(e){f(e);}function q(e){d(e);}function D(e,n,t="{current} of {total}"){let s=t.replace("{current}",String(e)).replace("{total}",String(n));f(s);}export{L as a,a as b,f as c,d,P as e,R as f,w as g,C as h,q as i,D as j};
@@ -1 +1 @@
1
- 'use strict';var r={hide(e){e.setAttribute("aria-hidden","true");},show(e){e.removeAttribute("aria-hidden");},setExpanded(e,t){e.setAttribute("aria-expanded",String(t));},setSelected(e,t){e.setAttribute("aria-selected",String(t));},setChecked(e,t){e.setAttribute("aria-checked",String(t));},setPressed(e,t){e.setAttribute("aria-pressed",String(t));},setDisabled(e,t){e.setAttribute("aria-disabled",String(t));},setBusy(e,t){e.setAttribute("aria-busy",String(t));},setCurrent(e,t){t==="false"?e.removeAttribute("aria-current"):e.setAttribute("aria-current",t);},setInvalid(e,t){t===false?e.removeAttribute("aria-invalid"):e.setAttribute("aria-invalid",String(t));},setLabel(e,t){t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label");},setLabelledBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-labelledby",i):e.removeAttribute("aria-labelledby");},setDescribedBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-describedby",i):e.removeAttribute("aria-describedby");},setControls(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-controls",i):e.removeAttribute("aria-controls");},setOwns(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-owns",i):e.removeAttribute("aria-owns");},setActiveDescendant(e,t){t?e.setAttribute("aria-activedescendant",t):e.removeAttribute("aria-activedescendant");},setHasPopup(e,t){t===false?e.removeAttribute("aria-haspopup"):e.setAttribute("aria-haspopup",String(t));},setLevel(e,t){e.setAttribute("aria-level",String(t));},setPosition(e,t,i){e.setAttribute("aria-posinset",String(t)),e.setAttribute("aria-setsize",String(i));},setValue(e,t){t.min!==void 0&&e.setAttribute("aria-valuemin",String(t.min)),t.max!==void 0&&e.setAttribute("aria-valuemax",String(t.max)),t.now!==void 0&&e.setAttribute("aria-valuenow",String(t.now)),t.text!==void 0&&e.setAttribute("aria-valuetext",t.text);},setRole(e,t){t?e.setAttribute("role",t):e.removeAttribute("role");},setModal(e,t){t?e.setAttribute("aria-modal","true"):e.removeAttribute("aria-modal");},setOrientation(e,t){e.setAttribute("aria-orientation",t);},setRequired(e,t){e.setAttribute("aria-required",String(t));},setReadOnly(e,t){e.setAttribute("aria-readonly",String(t));},setAutocomplete(e,t){e.setAttribute("aria-autocomplete",t);},setMultiSelectable(e,t){e.setAttribute("aria-multiselectable",String(t));},setSort(e,t){e.setAttribute("aria-sort",t);}};function l(e){let t={};return e.label&&(t["aria-label"]=e.label),e.labelledBy&&(t["aria-labelledby"]=Array.isArray(e.labelledBy)?e.labelledBy.join(" "):e.labelledBy),e.describedBy&&(t["aria-describedby"]=Array.isArray(e.describedBy)?e.describedBy.join(" "):e.describedBy),e.controls&&(t["aria-controls"]=Array.isArray(e.controls)?e.controls.join(" "):e.controls),e.owns&&(t["aria-owns"]=Array.isArray(e.owns)?e.owns.join(" "):e.owns),e.expanded!==void 0&&(t["aria-expanded"]=String(e.expanded)),e.selected!==void 0&&(t["aria-selected"]=String(e.selected)),e.checked!==void 0&&(t["aria-checked"]=String(e.checked)),e.pressed!==void 0&&(t["aria-pressed"]=String(e.pressed)),e.disabled!==void 0&&(t["aria-disabled"]=String(e.disabled)),e.hidden!==void 0&&(t["aria-hidden"]=String(e.hidden)),e.modal!==void 0&&(t["aria-modal"]=String(e.modal)),e.busy!==void 0&&(t["aria-busy"]=String(e.busy)),e.current&&(t["aria-current"]=e.current),e.invalid!==void 0&&(t["aria-invalid"]=String(e.invalid)),e.hasPopup!==void 0&&(t["aria-haspopup"]=String(e.hasPopup)),e.activeDescendant&&(t["aria-activedescendant"]=e.activeDescendant),e.level!==void 0&&(t["aria-level"]=String(e.level)),e.posInSet!==void 0&&(t["aria-posinset"]=String(e.posInSet)),e.setSize!==void 0&&(t["aria-setsize"]=String(e.setSize)),e.valueMin!==void 0&&(t["aria-valuemin"]=String(e.valueMin)),e.valueMax!==void 0&&(t["aria-valuemax"]=String(e.valueMax)),e.valueNow!==void 0&&(t["aria-valuenow"]=String(e.valueNow)),e.valueText&&(t["aria-valuetext"]=e.valueText),e.orientation&&(t["aria-orientation"]=e.orientation),e.required!==void 0&&(t["aria-required"]=String(e.required)),e.readOnly!==void 0&&(t["aria-readonly"]=String(e.readOnly)),e.autocomplete&&(t["aria-autocomplete"]=e.autocomplete),e.multiSelectable!==void 0&&(t["aria-multiselectable"]=String(e.multiSelectable)),e.sort&&(t["aria-sort"]=e.sort),e.role&&(t.role=e.role),t}function d(...e){let t=e.filter(Boolean);return t.length>0?t.join(" "):void 0}function u(e){if(e.getAttribute("aria-label"))return true;let t=e.getAttribute("aria-labelledby");return !!(t&&t.split(" ").some(n=>{let a=document.getElementById(n);return a&&a.textContent?.trim()})||e.textContent?.trim()||e.getAttribute("title")||"labels"in e&&e.labels?.length||e.tagName==="IMG"&&e.getAttribute("alt"))}exports.a=r;exports.b=l;exports.c=d;exports.d=u;
1
+ 'use strict';var l={hide(e){e.setAttribute("aria-hidden","true");},show(e){e.removeAttribute("aria-hidden");},setExpanded(e,t){e.setAttribute("aria-expanded",String(t));},setSelected(e,t){e.setAttribute("aria-selected",String(t));},setChecked(e,t){e.setAttribute("aria-checked",String(t));},setPressed(e,t){e.setAttribute("aria-pressed",String(t));},setDisabled(e,t){e.setAttribute("aria-disabled",String(t));},setBusy(e,t){e.setAttribute("aria-busy",String(t));},setCurrent(e,t){t==="false"?e.removeAttribute("aria-current"):e.setAttribute("aria-current",t);},setInvalid(e,t){t===false?e.removeAttribute("aria-invalid"):e.setAttribute("aria-invalid",String(t));},setLabel(e,t){t?e.setAttribute("aria-label",t):e.removeAttribute("aria-label");},setLabelledBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-labelledby",i):e.removeAttribute("aria-labelledby");},setDescribedBy(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-describedby",i):e.removeAttribute("aria-describedby");},setControls(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-controls",i):e.removeAttribute("aria-controls");},setOwns(e,...t){let i=t.filter(Boolean).join(" ");i?e.setAttribute("aria-owns",i):e.removeAttribute("aria-owns");},setActiveDescendant(e,t){t?e.setAttribute("aria-activedescendant",t):e.removeAttribute("aria-activedescendant");},setHasPopup(e,t){t===false?e.removeAttribute("aria-haspopup"):e.setAttribute("aria-haspopup",String(t));},setLevel(e,t){e.setAttribute("aria-level",String(t));},setPosition(e,t,i){e.setAttribute("aria-posinset",String(t)),e.setAttribute("aria-setsize",String(i));},setValue(e,t){t.min!==void 0&&e.setAttribute("aria-valuemin",String(t.min)),t.max!==void 0&&e.setAttribute("aria-valuemax",String(t.max)),t.now!==void 0&&e.setAttribute("aria-valuenow",String(t.now)),t.text!==void 0&&e.setAttribute("aria-valuetext",t.text);},setRole(e,t){t?e.setAttribute("role",t):e.removeAttribute("role");},setModal(e,t){t?e.setAttribute("aria-modal","true"):e.removeAttribute("aria-modal");},setOrientation(e,t){e.setAttribute("aria-orientation",t);},setRequired(e,t){e.setAttribute("aria-required",String(t));},setReadOnly(e,t){e.setAttribute("aria-readonly",String(t));},setAutocomplete(e,t){e.setAttribute("aria-autocomplete",t);},setMultiSelectable(e,t){e.setAttribute("aria-multiselectable",String(t));},setSort(e,t){e.setAttribute("aria-sort",t);}};function d(e){let t={};return e.label&&(t["aria-label"]=e.label),e.labelledBy&&(t["aria-labelledby"]=Array.isArray(e.labelledBy)?e.labelledBy.join(" "):e.labelledBy),e.describedBy&&(t["aria-describedby"]=Array.isArray(e.describedBy)?e.describedBy.join(" "):e.describedBy),e.controls&&(t["aria-controls"]=Array.isArray(e.controls)?e.controls.join(" "):e.controls),e.owns&&(t["aria-owns"]=Array.isArray(e.owns)?e.owns.join(" "):e.owns),e.expanded!==void 0&&(t["aria-expanded"]=String(e.expanded)),e.selected!==void 0&&(t["aria-selected"]=String(e.selected)),e.checked!==void 0&&(t["aria-checked"]=String(e.checked)),e.pressed!==void 0&&(t["aria-pressed"]=String(e.pressed)),e.disabled!==void 0&&(t["aria-disabled"]=String(e.disabled)),e.hidden!==void 0&&(t["aria-hidden"]=String(e.hidden)),e.modal!==void 0&&(t["aria-modal"]=String(e.modal)),e.busy!==void 0&&(t["aria-busy"]=String(e.busy)),e.current&&(t["aria-current"]=e.current),e.invalid!==void 0&&(t["aria-invalid"]=String(e.invalid)),e.hasPopup!==void 0&&(t["aria-haspopup"]=String(e.hasPopup)),e.activeDescendant&&(t["aria-activedescendant"]=e.activeDescendant),e.level!==void 0&&(t["aria-level"]=String(e.level)),e.posInSet!==void 0&&(t["aria-posinset"]=String(e.posInSet)),e.setSize!==void 0&&(t["aria-setsize"]=String(e.setSize)),e.valueMin!==void 0&&(t["aria-valuemin"]=String(e.valueMin)),e.valueMax!==void 0&&(t["aria-valuemax"]=String(e.valueMax)),e.valueNow!==void 0&&(t["aria-valuenow"]=String(e.valueNow)),e.valueText&&(t["aria-valuetext"]=e.valueText),e.orientation&&(t["aria-orientation"]=e.orientation),e.required!==void 0&&(t["aria-required"]=String(e.required)),e.readOnly!==void 0&&(t["aria-readonly"]=String(e.readOnly)),e.autocomplete&&(t["aria-autocomplete"]=e.autocomplete),e.multiSelectable!==void 0&&(t["aria-multiselectable"]=String(e.multiSelectable)),e.sort&&(t["aria-sort"]=e.sort),e.role&&(t.role=e.role),t}function u(...e){let t=e.filter(Boolean);return t.length>0?t.join(" "):void 0}function o(e){if(e.getAttribute("aria-label"))return true;let t=e.getAttribute("aria-labelledby");return !!(t&&t.split(" ").some(n=>{let a=document.getElementById(n);return a&&a.textContent?.trim()})||e.textContent?.trim()||e.getAttribute("title")||"labels"in e&&e.labels?.length||e.tagName==="IMG"&&e.getAttribute("alt"))}exports.a=l;exports.b=d;exports.c=u;exports.d=o;
@@ -0,0 +1 @@
1
+ function f(e){let t=e.key;switch(t){case " ":return "Space";case "Esc":return "Escape";case "Left":return "ArrowLeft";case "Right":return "ArrowRight";case "Up":return "ArrowUp";case "Down":return "ArrowDown";default:return t}}function g(e){let t=[];e.ctrlKey&&t.push("Ctrl"),e.altKey&&t.push("Alt"),e.shiftKey&&t.push("Shift"),e.metaKey&&t.push("Meta");let i=f(e);return ["Control","Alt","Shift","Meta"].includes(i)||t.push(i),t.join("+")}function b(e={},t={}){let{preventDefault:i=true,stopPropagation:d=true,targetSelector:n}=t,r=new Map(Object.entries(e)),a=null;function l(o){if(n&&!o.target.matches(n))return;let y=g(o),c=r.get(y);if(!c){let u=f(o);c=r.get(u);}c&&c(o)!==false&&(i&&o.preventDefault(),d&&o.stopPropagation());}function p(o){a&&s(),a=o,o.addEventListener("keydown",l);}function s(){a&&(a.removeEventListener("keydown",l),a=null);}function m(o,y){r.set(o,y);}function v(o){r.delete(o);}function h(){s(),r.clear();}return {attach:p,detach:s,on:m,off:v,destroy:h}}var K={menu:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),Enter:()=>e.onEnter?.(),Space:()=>e.onEnter?.(),Escape:()=>e.onEscape?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),tabs:e=>({ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),dialog:e=>({Escape:()=>e.onEscape?.()}),grid:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.(),"Ctrl+Home":()=>e.onCtrlHome?.(),"Ctrl+End":()=>e.onCtrlEnd?.()})};function E(e,t={}){let{timeout:i=500}=t,d="",n=null;function r(){d="",n&&(clearTimeout(n),n=null);}function a(l){return l.length!==1||l===" "?null:(n&&clearTimeout(n),d+=l.toLowerCase(),n=setTimeout(r,i),e.find(s=>s.toLowerCase().startsWith(d))??null)}return {type:a,reset:r,getSearch:()=>d}}export{f as a,g as b,b as c,K as d,E as e};
@@ -0,0 +1,3 @@
1
+ import {a}from'./chunk-25OQO77R.js';import {d}from'./chunk-5LRBCHHZ.js';var N=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]',"audio[controls]","video[controls]","details > summary:first-of-type","iframe"].join(","),$=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])','[contenteditable="true"]:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','details > summary:first-of-type:not([tabindex="-1"])','iframe:not([tabindex="-1"])'].join(",");function j(e){if(!(e instanceof HTMLElement)||e.hidden||e.style.display==="none"||e.style.visibility==="hidden")return false;let t=window.getComputedStyle(e);return !(t.display==="none"||t.visibility==="hidden"||!e.isConnected)}function q(e){return !(!(e instanceof HTMLElement)||!j(e)||!e.matches(N)||e.closest("[inert]"))}function O(e){return !q(e)||e.tabIndex<0?false:e.matches($)}function pe(e){return Array.from(e.querySelectorAll(N)).filter(q)}function h(e){return Array.from(e.querySelectorAll($)).filter(O).sort((o,r)=>{let i=Math.max(0,o.tabIndex),u=Math.max(0,r.tabIndex);return i===0&&u===0?0:i===0?1:u===0?-1:i-u})}function S(e){return h(e)[0]??null}function me(e){let t=h(e);return t[t.length-1]??null}function U(e){let t=document.activeElement;return t!==null&&e.contains(t)}function B(e,t,n=true){let o=h(e),r=o.indexOf(t);if(r===-1)return o[0]??null;let i=r+1;return i<o.length?o[i]:n?o[0]??null:null}function _(e,t,n=true){let o=h(e),r=o.indexOf(t);if(r===-1)return o[o.length-1]??null;let i=r-1;return i>=0?o[i]:n?o[o.length-1]??null:null}function ge(e,t){return t.contains(e)}function z(e,t=document.body){return e?typeof e=="string"?t.querySelector(e):typeof e=="function"?e():e:null}var K=null,C=new Set;function Y(){return typeof process<"u"&&process.env?.NODE_ENV!=="production"}function xe(e){K=e;}function J(e){return `${e.component}:${e.message}`}function x(e){if(!Y())return;let t=J(e);if(C.has(t))return;if(C.add(t),K){K(e);return}let n=`[compa11y/${e.component}]`,o=Q(e.type),r=e.suggestion?`${e.message}
2
+
3
+ \u{1F4A1} Suggestion: ${e.suggestion}`:e.message;switch(e.type){case "error":console.error(`%c${n}%c ${r}`,o,"");break;case "warning":console.warn(`%c${n}%c ${r}`,o,"");break;case "info":console.info(`%c${n}%c ${r}`,o,"");break}e.element&&console.log("Element:",e.element);}function Q(e){switch(e){case "error":return "background: #ff5555; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "warning":return "background: #ffaa00; color: black; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "info":return "background: #5555ff; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;"}}function he(){C.clear();}var I={accessibleLabel(e,t,n="aria-label"){e&&(d(e)||x({type:"error",component:t,message:"Missing accessible label. Screen reader users will not be able to understand this element.",suggestion:`Add ${n}, aria-labelledby, or visible text content.`,element:e}));},requiredProp(e,t,n){(e==null||e==="")&&x({type:"error",component:n,message:`Missing required prop "${t}".`,suggestion:`Provide a value for the "${t}" prop.`});},validRole(e,t,n){if(!e)return;new Set(["alert","alertdialog","application","article","banner","button","cell","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","navigation","none","note","option","presentation","progressbar","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"]).has(e)||x({type:"warning",component:t,message:`Invalid ARIA role "${e}".`,suggestion:"Use a valid ARIA role from the WAI-ARIA specification.",element:n});},keyboardAccessible(e,t,n){if(e&&n.onClick&&!n.onKeyDown){let o=e.tagName.toLowerCase(),r=e.getAttribute("role");if(["button","a","input","select","textarea"].includes(o))return;r&&["button","link","menuitem","option","tab"].includes(r)&&x({type:"warning",component:t,message:"Element has onClick but no onKeyDown handler.",suggestion:"Add keyboard event handling for Enter and Space keys.",element:e});}},tabIndex(e,t,n){e!==void 0&&e>0&&x({type:"warning",component:t,message:`Positive tabIndex (${e}) disrupts natural tab order.`,suggestion:"Use tabIndex={0} or tabIndex={-1} instead. Rely on DOM order for tab sequence.",element:n});},dialogAutoFocus(e,t){e||x({type:"info",component:t,message:"No initial focus element specified for dialog.",suggestion:"Consider setting initialFocus to guide keyboard users."});},formLabel(e,t,n){if(!e)return;t||e.getAttribute("aria-label")||e.getAttribute("aria-labelledby")||e.labels?.length||x({type:"error",component:n,message:"Form input is missing an accessible label.",suggestion:"Add a <label>, aria-label, or aria-labelledby.",element:e});},imageAlt(e,t){if(!e||e.tagName!=="IMG")return;let n=e.getAttribute("alt"),o=e.getAttribute("role");n===null&&o!=="presentation"&&o!=="none"&&x({type:"error",component:t,message:"Image is missing alt attribute.",suggestion:'Add alt="" for decorative images or descriptive alt text for meaningful images.',element:e});}};function D(e){return {error:(t,n,o)=>x({type:"error",component:e,message:t,suggestion:n,element:o}),warning:(t,n,o)=>x({type:"warning",component:e,message:t,suggestion:n,element:o}),info:(t,n,o)=>x({type:"info",component:e,message:t,suggestion:n,element:o}),checks:{accessibleLabel:(t,n)=>I.accessibleLabel(t,e,n),requiredProp:(t,n)=>I.requiredProp(t,n,e),keyboardAccessible:(t,n)=>I.keyboardAccessible(t,e,n),tabIndex:(t,n)=>I.tabIndex(t,e,n)}}}var y=[],X=D("FocusTrap");function Z(e,t={}){let{initialFocus:n,returnFocus:o=true,clickOutsideDeactivates:r=false,escapeDeactivates:i=true,onDeactivate:u,onEscapeFocus:l}=t,s=false,b=false,d=null;function T(c){b||!s||(c.key==="Tab"?F(c):c.key==="Escape"&&i&&(c.preventDefault(),c.stopPropagation(),g()));}function F(c){let v=h(e);if(v.length===0){c.preventDefault();return}let k=v[0],M=v[v.length-1],A=document.activeElement;c.shiftKey?(A===k||!e.contains(A))&&(c.preventDefault(),M.focus()):(A===M||!e.contains(A))&&(c.preventDefault(),k.focus());}function m(c){if(b||!s)return;let v=c.target;e.contains(v)||(l?.(v),S(e)?.focus());}function f(c){if(b||!s)return;let v=c.target;r&&!e.contains(v)&&g();}function p(){if(!s){d=document.activeElement,y.push(R);for(let c=0;c<y.length-1;c++)y[c].pause();document.addEventListener("keydown",T,true),document.addEventListener("focusin",m,true),document.addEventListener("click",f,true),s=true,requestAnimationFrame(()=>{if(!s)return;let c=z(n,e);if(c)c.focus();else {let v=S(e);v?v.focus():(X.warning("No focusable elements found inside the focus trap container. The container itself will be focused.","Add focusable elements (buttons, inputs, links) inside the trap container.",e),e.setAttribute("tabindex","-1"),e.focus());}});}}function a(c){if(!s)return;document.removeEventListener("keydown",T,true),document.removeEventListener("focusin",m,true),document.removeEventListener("click",f,true),s=false,b=false;let v=y.indexOf(R);if(v>-1&&y.splice(v,1),y[y.length-1]?.unpause(),o&&d){let M=typeof o=="boolean"?d:o;requestAnimationFrame(()=>{M&&"focus"in M&&M.focus();});}c&&u?.();}function g(){a(true);}function L(){a(false);}function H(){!s||b||(b=true);}function w(){!s||!b||(b=false,U(e)||S(e)?.focus());}let R={activate:p,deactivate:g,destroy:L,pause:H,unpause:w,isActive:()=>s,isPaused:()=>b};return R}function ee(){return y[y.length-1]??null}function te(){return y.length>0}var E={hadKeyboardEvent:true,isPointerInput:false,lastFocusSource:"unknown"},P=false,ne=new Set(["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"," ","Home","End","PageUp","PageDown","Escape"]);function oe(){if(!a()||P)return ()=>{};P=true;function e(i){ne.has(i.key)&&(E.hadKeyboardEvent=true,E.isPointerInput=false,E.lastFocusSource="keyboard");}function t(i){E.isPointerInput=true,E.hadKeyboardEvent=false,E.lastFocusSource="pointerType"in i&&i.pointerType==="touch"?"touch":"mouse";}function n(i){let u=i.target;u instanceof HTMLElement&&(E.hadKeyboardEvent||re(u))&&(u.dataset.compa11yFocusVisible="true");}function o(i){let u=i.target;u instanceof HTMLElement&&delete u.dataset.compa11yFocusVisible;}function r(){document.visibilityState==="hidden"&&(E.hadKeyboardEvent=true);}return document.addEventListener("keydown",e,true),document.addEventListener("mousedown",t,true),document.addEventListener("pointerdown",t,true),document.addEventListener("focus",n,true),document.addEventListener("blur",o,true),document.addEventListener("visibilitychange",r,true),()=>{document.removeEventListener("keydown",e,true),document.removeEventListener("mousedown",t,true),document.removeEventListener("pointerdown",t,true),document.removeEventListener("focus",n,true),document.removeEventListener("blur",o,true),document.removeEventListener("visibilitychange",r,true),P=false;}}function re(e){let t=e.tagName.toLowerCase(),n=e.getAttribute("type")?.toLowerCase();return !!(t==="input"&&(!n||n==="text"||n==="email"||n==="password"||n==="search"||n==="tel"||n==="url"||n==="number")||t==="textarea"||e.isContentEditable)}function ie(){return E.hadKeyboardEvent}function se(e){return e.dataset.compa11yFocusVisible==="true"}function ue(){return E.lastFocusSource}function ae(e,t){t?e.dataset.compa11yFocusVisible="true":delete e.dataset.compa11yFocusVisible;}function le(e,t){E.hadKeyboardEvent=true,E.lastFocusSource="keyboard",e.focus(t);}function ce(e,t={}){let{contain:n=false,restoreFocus:o=false,autoFocus:r=false}=t,i=null,u=false;o&&(i=document.activeElement);function l(){return u?[]:h(e)}function s(){let a=document.activeElement;return a&&e.contains(a)?a:null}function b(){if(u)return;l()[0]?.focus();}function d(){if(u)return;let a=l();a[a.length-1]?.focus();}function T({wrap:a=true}={}){if(u)return;let g=s();if(!g){b();return}B(e,g,a)?.focus();}function F({wrap:a=true}={}){if(u)return;let g=s();if(!g){d();return}_(e,g,a)?.focus();}function m(a){if(u)return;l()[a]?.focus();}function f(a){if(!(u||!n)&&a.key==="Tab"){let g=l();if(g.length===0){a.preventDefault();return}let L=g[0],H=g[g.length-1],w=s();a.shiftKey&&w===L?(a.preventDefault(),H.focus()):!a.shiftKey&&w===H&&(a.preventDefault(),L.focus());}}function p(){u||(u=true,document.removeEventListener("keydown",f,true),o&&i&&i.focus());}return n&&document.addEventListener("keydown",f,true),r&&requestAnimationFrame(()=>{u||b();}),{focusFirst:b,focusLast:d,focusNext:T,focusPrevious:F,focusAt:m,getFocused:s,getElements:l,destroy:p}}var de=D("RovingTabindex");function fe(e,t,n={}){let{initialIndex:o=0,orientation:r="both",wrap:i=true,onSelectionChange:u}=n,l=[],s=o;function b(){l=Array.from(e.querySelectorAll(t)),l.length===0&&de.warning(`No elements matching "${t}" found in the container. Roving tabindex has nothing to manage.`,"Ensure the container has child elements matching the selector.",e),l.forEach((m,f)=>{m.setAttribute("tabindex",f===s?"0":"-1");});}function d(m){if(l.length===0)return;let f=m;f<0?f=i?l.length-1:0:f>=l.length&&(f=i?0:l.length-1);let p=l[s],a=l[f];p&&p.setAttribute("tabindex","-1"),a&&(a.setAttribute("tabindex","0"),a.focus(),u?.(f,a)),s=f;}function T(m){let f=m.target;if(!l.includes(f))return;let p=false;switch(m.key){case "ArrowRight":(r==="horizontal"||r==="both")&&(d(s+1),p=true);break;case "ArrowLeft":(r==="horizontal"||r==="both")&&(d(s-1),p=true);break;case "ArrowDown":(r==="vertical"||r==="both")&&(d(s+1),p=true);break;case "ArrowUp":(r==="vertical"||r==="both")&&(d(s-1),p=true);break;case "Home":d(0),p=true;break;case "End":d(l.length-1),p=true;break}p&&(m.preventDefault(),m.stopPropagation());}function F(m){let f=m.target,p=l.indexOf(f);if(p!==-1&&p!==s){let a=l[s];a&&a.setAttribute("tabindex","-1"),f.setAttribute("tabindex","0"),s=p;}}return b(),e.addEventListener("keydown",T),e.addEventListener("focusin",F),{next:()=>d(s+1),previous:()=>d(s-1),first:()=>d(0),last:()=>d(l.length-1),goto:d,getIndex:()=>s,update:b,destroy:()=>{e.removeEventListener("keydown",T),e.removeEventListener("focusin",F);}}}function G(e,t={}){let{scope:n=e.parentElement??document.body,prefer:o="previous"}=t,r=h(n),i=r.indexOf(e);i===-1&&(i=r.findIndex(d=>e.compareDocumentPosition(d)&Node.DOCUMENT_POSITION_FOLLOWING),i===-1&&(i=r.length));let u=i-1,l=i+1,s=u>=0&&r[u]!==e?r[u]:null,b=l<r.length&&r[l]!==e?r[l]:null;return o==="previous"?s??b:b??s}function be(e){let t=e??null;function n(i){t=i??document.activeElement??null;}function o(i={}){let{fallback:u,prefer:l="previous"}=i;if(!t){u?.focus();return}if(t.isConnected&&O(t)){t.focus(),t=null;return}if(t.isConnected){let s=G(t,{prefer:l});if(s){s.focus(),t=null;return}}u&&u.focus(),t=null;}function r(){t=null;}return {get element(){return t},save:n,return:o,clear:r}}export{ae as A,le as B,ce as C,fe as D,G as E,be as F,N as a,$ as b,j as c,q as d,O as e,pe as f,h as g,S as h,me as i,U as j,B as k,_ as l,ge as m,z as n,xe as o,x as p,he as q,I as r,D as s,Z as t,ee as u,te as v,oe as w,ie as x,se as y,ue as z};
@@ -0,0 +1 @@
1
+ 'use strict';var chunkC7U5KZG2_cjs=require('./chunk-C7U5KZG2.cjs');var o=null,i=null,m=false,c=[],r=null,g=null,v=0,S=500;function T(){return {position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0"}}function y(e){let n=document.createElement("div");n.setAttribute("role","status"),n.setAttribute("aria-live",e),n.setAttribute("aria-atomic","true"),n.setAttribute("aria-relevant","additions text"),n.id=`compa11y-announcer-${e}`;let t=T();return Object.assign(n.style,t),document.body.appendChild(n),{element:n,politeness:e}}function L(){return !chunkC7U5KZG2_cjs.a()||m?()=>{}:(m=true,o=y("polite"),i=y("assertive"),()=>{o&&(o.element.remove(),o=null),i&&(i.element.remove(),i=null),r&&(clearTimeout(r),r=null),c=[],g=null,v=0,m=false;})}function h(){!m&&chunkC7U5KZG2_cjs.a()&&L();}function A(e){e.element.textContent="";}function a(e,n={}){if(!chunkC7U5KZG2_cjs.a())return;let{politeness:t="polite",delay:s=0,clearPrevious:l=false,timeout:x=7e3}=n;h();let b=Date.now();if(e===g&&b-v<S)return;g=e,v=b;let u=t==="assertive"?i:o;if(!u)return;let O=()=>{l&&A(u),u.element.textContent="",requestAnimationFrame(()=>{u.element.textContent=e,x>0&&setTimeout(()=>{u.element.textContent===e&&(u.element.textContent="");},x);});};s>0?setTimeout(O,s):O();}function f(e,n){a(e,{...n,politeness:"polite"});}function d(e,n){a(e,{...n,politeness:"assertive"});}function P(){o&&A(o),i&&A(i);}function R(e,n={}){let{debounce:t=150,...s}=n;c.push({message:e,options:s}),r&&clearTimeout(r),r=setTimeout(()=>{let l=c[c.length-1];l&&a(l.message,l.options),c=[],r=null;},t);}function w(e={}){return {announce:(n,t)=>a(n,{...e,...t}),polite:(n,t)=>f(n,{...e,...t}),assertive:(n,t)=>d(n,{...e,...t}),queue:(n,t)=>R(n,{...e,...t}),clear:P}}function C(e){f(e);}function q(e){d(e);}function D(e,n,t="{current} of {total}"){let s=t.replace("{current}",String(e)).replace("{total}",String(n));f(s);}exports.a=L;exports.b=a;exports.c=f;exports.d=d;exports.e=P;exports.f=R;exports.g=w;exports.h=C;exports.i=q;exports.j=D;
@@ -1 +1 @@
1
- 'use strict';var chunkAL3UYWIX_cjs=require('../chunk-AL3UYWIX.cjs');require('../chunk-7BL2ABLF.cjs');Object.defineProperty(exports,"createFocusReturn",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.A}});Object.defineProperty(exports,"createFocusScope",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.x}});Object.defineProperty(exports,"createFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.o}});Object.defineProperty(exports,"createRovingTabindex",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.y}});Object.defineProperty(exports,"findFocusNeighbor",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.z}});Object.defineProperty(exports,"focusWithVisibleRing",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.w}});Object.defineProperty(exports,"getActiveFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.p}});Object.defineProperty(exports,"getLastFocusSource",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.u}});Object.defineProperty(exports,"hasFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.q}});Object.defineProperty(exports,"hasVisibleFocus",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.t}});Object.defineProperty(exports,"initFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.r}});Object.defineProperty(exports,"isFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.s}});Object.defineProperty(exports,"setFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.v}});
1
+ 'use strict';var chunkLBGAE624_cjs=require('../chunk-LBGAE624.cjs');require('../chunk-C7U5KZG2.cjs'),require('../chunk-S5TRVOSB.cjs');Object.defineProperty(exports,"createFocusReturn",{enumerable:true,get:function(){return chunkLBGAE624_cjs.F}});Object.defineProperty(exports,"createFocusScope",{enumerable:true,get:function(){return chunkLBGAE624_cjs.C}});Object.defineProperty(exports,"createFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.t}});Object.defineProperty(exports,"createRovingTabindex",{enumerable:true,get:function(){return chunkLBGAE624_cjs.D}});Object.defineProperty(exports,"findFocusNeighbor",{enumerable:true,get:function(){return chunkLBGAE624_cjs.E}});Object.defineProperty(exports,"focusWithVisibleRing",{enumerable:true,get:function(){return chunkLBGAE624_cjs.B}});Object.defineProperty(exports,"getActiveFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.u}});Object.defineProperty(exports,"getLastFocusSource",{enumerable:true,get:function(){return chunkLBGAE624_cjs.z}});Object.defineProperty(exports,"hasFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.v}});Object.defineProperty(exports,"hasVisibleFocus",{enumerable:true,get:function(){return chunkLBGAE624_cjs.y}});Object.defineProperty(exports,"initFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.w}});Object.defineProperty(exports,"isFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.x}});Object.defineProperty(exports,"setFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.A}});
@@ -1 +1 @@
1
- export{A as createFocusReturn,x as createFocusScope,o as createFocusTrap,y as createRovingTabindex,z as findFocusNeighbor,w as focusWithVisibleRing,p as getActiveFocusTrap,u as getLastFocusSource,q as hasFocusTrap,t as hasVisibleFocus,r as initFocusVisible,s as isFocusVisible,v as setFocusVisible}from'../chunk-7RLRK53P.js';import'../chunk-C3VZQUKG.js';
1
+ export{F as createFocusReturn,C as createFocusScope,t as createFocusTrap,D as createRovingTabindex,E as findFocusNeighbor,B as focusWithVisibleRing,u as getActiveFocusTrap,z as getLastFocusSource,v as hasFocusTrap,y as hasVisibleFocus,w as initFocusVisible,x as isFocusVisible,A as setFocusVisible}from'../chunk-UV66DEGV.js';import'../chunk-25OQO77R.js';import'../chunk-5LRBCHHZ.js';
package/dist/index.cjs CHANGED
@@ -1,3 +1 @@
1
- 'use strict';var chunkAL3UYWIX_cjs=require('./chunk-AL3UYWIX.cjs'),chunkEM45V5TK_cjs=require('./chunk-EM45V5TK.cjs'),chunkAQ6HEUSD_cjs=require('./chunk-AQ6HEUSD.cjs'),chunk7BL2ABLF_cjs=require('./chunk-7BL2ABLF.cjs'),chunkKQUAJKTG_cjs=require('./chunk-KQUAJKTG.cjs');var g=0,d="compa11y";function u(e){let n=++g;return e?`${d}-${e}-${n}`:`${d}-${n}`}function $e(e,n){let r=u(n),t={};for(let o of e)t[o]=`${r}-${o}`;return t}function we(){g=0;}function Ae(e){let n=u(e);return {id:n,generate:r=>`${n}-${r}`,generateMultiple:r=>{let t={};for(let o of r)t[o]=`${n}-${o}`;return t}}}var a=null,l=new Set;function p(){return typeof process<"u"&&process.env?.NODE_ENV!=="production"}function b(e){a=e;}function f(e){return `${e.component}:${e.message}`}function i(e){if(!p())return;let n=f(e);if(l.has(n))return;if(l.add(n),a){a(e);return}let r=`[compa11y/${e.component}]`,t=m(e.type),o=e.suggestion?`${e.message}
2
-
3
- \u{1F4A1} Suggestion: ${e.suggestion}`:e.message;switch(e.type){case "error":console.error(`%c${r}%c ${o}`,t,"");break;case "warning":console.warn(`%c${r}%c ${o}`,t,"");break;case "info":console.info(`%c${r}%c ${o}`,t,"");break}e.element&&console.log("Element:",e.element);}function m(e){switch(e){case "error":return "background: #ff5555; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "warning":return "background: #ffaa00; color: black; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "info":return "background: #5555ff; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;"}}function x(){l.clear();}var s={accessibleLabel(e,n,r="aria-label"){e&&(chunkKQUAJKTG_cjs.d(e)||i({type:"error",component:n,message:"Missing accessible label. Screen reader users will not be able to understand this element.",suggestion:`Add ${r}, aria-labelledby, or visible text content.`,element:e}));},requiredProp(e,n,r){(e==null||e==="")&&i({type:"error",component:r,message:`Missing required prop "${n}".`,suggestion:`Provide a value for the "${n}" prop.`});},validRole(e,n,r){if(!e)return;new Set(["alert","alertdialog","application","article","banner","button","cell","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","navigation","none","note","option","presentation","progressbar","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"]).has(e)||i({type:"warning",component:n,message:`Invalid ARIA role "${e}".`,suggestion:"Use a valid ARIA role from the WAI-ARIA specification.",element:r});},keyboardAccessible(e,n,r){if(e&&r.onClick&&!r.onKeyDown){let t=e.tagName.toLowerCase(),o=e.getAttribute("role");if(["button","a","input","select","textarea"].includes(t))return;o&&["button","link","menuitem","option","tab"].includes(o)&&i({type:"warning",component:n,message:"Element has onClick but no onKeyDown handler.",suggestion:"Add keyboard event handling for Enter and Space keys.",element:e});}},tabIndex(e,n,r){e!==void 0&&e>0&&i({type:"warning",component:n,message:`Positive tabIndex (${e}) disrupts natural tab order.`,suggestion:"Use tabIndex={0} or tabIndex={-1} instead. Rely on DOM order for tab sequence.",element:r});},dialogAutoFocus(e,n){e||i({type:"info",component:n,message:"No initial focus element specified for dialog.",suggestion:"Consider setting initialFocus to guide keyboard users."});},formLabel(e,n,r){if(!e)return;n||e.getAttribute("aria-label")||e.getAttribute("aria-labelledby")||e.labels?.length||i({type:"error",component:r,message:"Form input is missing an accessible label.",suggestion:"Add a <label>, aria-label, or aria-labelledby.",element:e});},imageAlt(e,n){if(!e||e.tagName!=="IMG")return;let r=e.getAttribute("alt"),t=e.getAttribute("role");r===null&&t!=="presentation"&&t!=="none"&&i({type:"error",component:n,message:"Image is missing alt attribute.",suggestion:'Add alt="" for decorative images or descriptive alt text for meaningful images.',element:e});}};function y(e){return {error:(n,r,t)=>i({type:"error",component:e,message:n,suggestion:r,element:t}),warning:(n,r,t)=>i({type:"warning",component:e,message:n,suggestion:r,element:t}),info:(n,r,t)=>i({type:"info",component:e,message:n,suggestion:r,element:t}),checks:{accessibleLabel:(n,r)=>s.accessibleLabel(n,e,r),requiredProp:(n,r)=>s.requiredProp(n,r,e),keyboardAccessible:(n,r)=>s.keyboardAccessible(n,e,r),tabIndex:(n,r)=>s.tabIndex(n,e,r)}}}function We(){let e=[];return import('./focus/index.cjs').then(({initFocusVisible:n})=>{e.push(n());}),import('./announcer/index.cjs').then(({initAnnouncer:n})=>{e.push(n());}),()=>{e.forEach(n=>n());}}Object.defineProperty(exports,"FOCUSABLE_SELECTORS",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.a}});Object.defineProperty(exports,"TABBABLE_SELECTORS",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.b}});Object.defineProperty(exports,"containsFocus",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.j}});Object.defineProperty(exports,"createFocusReturn",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.A}});Object.defineProperty(exports,"createFocusScope",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.x}});Object.defineProperty(exports,"createFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.o}});Object.defineProperty(exports,"createRovingTabindex",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.y}});Object.defineProperty(exports,"findFocusNeighbor",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.z}});Object.defineProperty(exports,"focusWithVisibleRing",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.w}});Object.defineProperty(exports,"getActiveFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.p}});Object.defineProperty(exports,"getFirstFocusable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.h}});Object.defineProperty(exports,"getFocusableElements",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.f}});Object.defineProperty(exports,"getLastFocusSource",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.u}});Object.defineProperty(exports,"getLastFocusable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.i}});Object.defineProperty(exports,"getNextFocusable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.k}});Object.defineProperty(exports,"getPreviousFocusable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.l}});Object.defineProperty(exports,"getTabbableElements",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.g}});Object.defineProperty(exports,"hasFocusTrap",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.q}});Object.defineProperty(exports,"hasVisibleFocus",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.t}});Object.defineProperty(exports,"initFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.r}});Object.defineProperty(exports,"isFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.s}});Object.defineProperty(exports,"isFocusable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.d}});Object.defineProperty(exports,"isTabbable",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.e}});Object.defineProperty(exports,"isVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.c}});Object.defineProperty(exports,"isWithinContainer",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.m}});Object.defineProperty(exports,"resolveElement",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.n}});Object.defineProperty(exports,"setFocusVisible",{enumerable:true,get:function(){return chunkAL3UYWIX_cjs.v}});Object.defineProperty(exports,"KeyboardPatterns",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.d}});Object.defineProperty(exports,"createKeyboardManager",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.c}});Object.defineProperty(exports,"createTypeAhead",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.e}});Object.defineProperty(exports,"getKeyCombo",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.b}});Object.defineProperty(exports,"normalizeKey",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.a}});Object.defineProperty(exports,"announce",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.b}});Object.defineProperty(exports,"announceAssertive",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.d}});Object.defineProperty(exports,"announceError",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.i}});Object.defineProperty(exports,"announcePolite",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.c}});Object.defineProperty(exports,"announceProgress",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.j}});Object.defineProperty(exports,"announceStatus",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.h}});Object.defineProperty(exports,"clearAnnouncements",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.e}});Object.defineProperty(exports,"createAnnouncer",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.g}});Object.defineProperty(exports,"initAnnouncer",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.a}});Object.defineProperty(exports,"queueAnnouncement",{enumerable:true,get:function(){return chunkAQ6HEUSD_cjs.f}});Object.defineProperty(exports,"createMediaQueryListener",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.k}});Object.defineProperty(exports,"getScreenReaderHints",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.j}});Object.defineProperty(exports,"isAndroid",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.d}});Object.defineProperty(exports,"isBrowser",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.a}});Object.defineProperty(exports,"isIOS",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.c}});Object.defineProperty(exports,"isMac",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.b}});Object.defineProperty(exports,"isTouchDevice",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.f}});Object.defineProperty(exports,"isWindows",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.e}});Object.defineProperty(exports,"prefersDarkMode",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.i}});Object.defineProperty(exports,"prefersHighContrast",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.h}});Object.defineProperty(exports,"prefersReducedMotion",{enumerable:true,get:function(){return chunk7BL2ABLF_cjs.g}});Object.defineProperty(exports,"aria",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.a}});Object.defineProperty(exports,"buildAriaProps",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.b}});Object.defineProperty(exports,"hasAccessibleName",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.d}});Object.defineProperty(exports,"mergeAriaIds",{enumerable:true,get:function(){return chunkKQUAJKTG_cjs.c}});exports.checks=s;exports.clearWarnings=x;exports.createComponentWarnings=y;exports.createIdScope=Ae;exports.generateId=u;exports.generateIds=$e;exports.initCompa11y=We;exports.resetIdCounter=we;exports.setWarningHandler=b;exports.warn=i;
1
+ 'use strict';var chunkLBGAE624_cjs=require('./chunk-LBGAE624.cjs'),chunk5OQKJSL6_cjs=require('./chunk-5OQKJSL6.cjs'),chunkX5U6WLYD_cjs=require('./chunk-X5U6WLYD.cjs'),chunkC7U5KZG2_cjs=require('./chunk-C7U5KZG2.cjs');require('./chunk-QSOIUQG6.cjs');var chunkS5TRVOSB_cjs=require('./chunk-S5TRVOSB.cjs');var a=0,i="compa11y";function s(o){let e=++a;return o?`${i}-${o}-${e}`:`${i}-${e}`}function Ee(o,e){let t=s(e),r={};for(let n of o)r[n]=`${t}-${n}`;return r}function fe(){a=0;}function ke(o){let e=s(o);return {id:e,generate:t=>`${e}-${t}`,generateMultiple:t=>{let r={};for(let n of t)r[n]=`${e}-${n}`;return r}}}var Ce={isCollapsed:true,marks:{},block:"paragraph",canUndo:false,canRedo:false,link:null},ye={bold:true,italic:true,underline:true,strikethrough:false,headings:true,lists:true,link:true,code:true,blockquote:true,image:false,table:false};function Le(){let o=[];return import('./focus/index.cjs').then(({initFocusVisible:e})=>{o.push(e());}),import('./announcer/index.cjs').then(({initAnnouncer:e})=>{o.push(e());}),()=>{o.forEach(e=>e());}}Object.defineProperty(exports,"FOCUSABLE_SELECTORS",{enumerable:true,get:function(){return chunkLBGAE624_cjs.a}});Object.defineProperty(exports,"TABBABLE_SELECTORS",{enumerable:true,get:function(){return chunkLBGAE624_cjs.b}});Object.defineProperty(exports,"checks",{enumerable:true,get:function(){return chunkLBGAE624_cjs.r}});Object.defineProperty(exports,"clearWarnings",{enumerable:true,get:function(){return chunkLBGAE624_cjs.q}});Object.defineProperty(exports,"containsFocus",{enumerable:true,get:function(){return chunkLBGAE624_cjs.j}});Object.defineProperty(exports,"createComponentWarnings",{enumerable:true,get:function(){return chunkLBGAE624_cjs.s}});Object.defineProperty(exports,"createFocusReturn",{enumerable:true,get:function(){return chunkLBGAE624_cjs.F}});Object.defineProperty(exports,"createFocusScope",{enumerable:true,get:function(){return chunkLBGAE624_cjs.C}});Object.defineProperty(exports,"createFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.t}});Object.defineProperty(exports,"createRovingTabindex",{enumerable:true,get:function(){return chunkLBGAE624_cjs.D}});Object.defineProperty(exports,"findFocusNeighbor",{enumerable:true,get:function(){return chunkLBGAE624_cjs.E}});Object.defineProperty(exports,"focusWithVisibleRing",{enumerable:true,get:function(){return chunkLBGAE624_cjs.B}});Object.defineProperty(exports,"getActiveFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.u}});Object.defineProperty(exports,"getFirstFocusable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.h}});Object.defineProperty(exports,"getFocusableElements",{enumerable:true,get:function(){return chunkLBGAE624_cjs.f}});Object.defineProperty(exports,"getLastFocusSource",{enumerable:true,get:function(){return chunkLBGAE624_cjs.z}});Object.defineProperty(exports,"getLastFocusable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.i}});Object.defineProperty(exports,"getNextFocusable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.k}});Object.defineProperty(exports,"getPreviousFocusable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.l}});Object.defineProperty(exports,"getTabbableElements",{enumerable:true,get:function(){return chunkLBGAE624_cjs.g}});Object.defineProperty(exports,"hasFocusTrap",{enumerable:true,get:function(){return chunkLBGAE624_cjs.v}});Object.defineProperty(exports,"hasVisibleFocus",{enumerable:true,get:function(){return chunkLBGAE624_cjs.y}});Object.defineProperty(exports,"initFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.w}});Object.defineProperty(exports,"isFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.x}});Object.defineProperty(exports,"isFocusable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.d}});Object.defineProperty(exports,"isTabbable",{enumerable:true,get:function(){return chunkLBGAE624_cjs.e}});Object.defineProperty(exports,"isVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.c}});Object.defineProperty(exports,"isWithinContainer",{enumerable:true,get:function(){return chunkLBGAE624_cjs.m}});Object.defineProperty(exports,"resolveElement",{enumerable:true,get:function(){return chunkLBGAE624_cjs.n}});Object.defineProperty(exports,"setFocusVisible",{enumerable:true,get:function(){return chunkLBGAE624_cjs.A}});Object.defineProperty(exports,"setWarningHandler",{enumerable:true,get:function(){return chunkLBGAE624_cjs.o}});Object.defineProperty(exports,"warn",{enumerable:true,get:function(){return chunkLBGAE624_cjs.p}});Object.defineProperty(exports,"KeyboardPatterns",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.d}});Object.defineProperty(exports,"createKeyboardManager",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.c}});Object.defineProperty(exports,"createTypeAhead",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.e}});Object.defineProperty(exports,"getKeyCombo",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.b}});Object.defineProperty(exports,"normalizeKey",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.a}});Object.defineProperty(exports,"announce",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.b}});Object.defineProperty(exports,"announceAssertive",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.d}});Object.defineProperty(exports,"announceError",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.i}});Object.defineProperty(exports,"announcePolite",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.c}});Object.defineProperty(exports,"announceProgress",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.j}});Object.defineProperty(exports,"announceStatus",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.h}});Object.defineProperty(exports,"clearAnnouncements",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.e}});Object.defineProperty(exports,"createAnnouncer",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.g}});Object.defineProperty(exports,"initAnnouncer",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.a}});Object.defineProperty(exports,"queueAnnouncement",{enumerable:true,get:function(){return chunkX5U6WLYD_cjs.f}});Object.defineProperty(exports,"createMediaQueryListener",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.m}});Object.defineProperty(exports,"getScreenReaderHints",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.l}});Object.defineProperty(exports,"isAndroid",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.d}});Object.defineProperty(exports,"isBrowser",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.a}});Object.defineProperty(exports,"isIOS",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.c}});Object.defineProperty(exports,"isMac",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.b}});Object.defineProperty(exports,"isTouchDevice",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.f}});Object.defineProperty(exports,"isWindows",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.e}});Object.defineProperty(exports,"pointerCoarse",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.j}});Object.defineProperty(exports,"pointerFine",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.k}});Object.defineProperty(exports,"prefersDarkMode",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.i}});Object.defineProperty(exports,"prefersHighContrast",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.h}});Object.defineProperty(exports,"prefersReducedMotion",{enumerable:true,get:function(){return chunkC7U5KZG2_cjs.g}});Object.defineProperty(exports,"aria",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.a}});Object.defineProperty(exports,"buildAriaProps",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.b}});Object.defineProperty(exports,"hasAccessibleName",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.d}});Object.defineProperty(exports,"mergeAriaIds",{enumerable:true,get:function(){return chunkS5TRVOSB_cjs.c}});exports.DEFAULT_RTE_FEATURES=ye;exports.EMPTY_SELECTION_STATE=Ce;exports.createIdScope=ke;exports.generateId=s;exports.generateIds=Ee;exports.initCompa11y=Le;exports.resetIdCounter=fe;
package/dist/index.d.cts CHANGED
@@ -134,6 +134,14 @@ declare function prefersHighContrast(): boolean;
134
134
  * Detect if user prefers dark color scheme
135
135
  */
136
136
  declare function prefersDarkMode(): boolean;
137
+ /**
138
+ * Detect if the primary pointer is coarse (touch/stylus)
139
+ */
140
+ declare function pointerCoarse(): boolean;
141
+ /**
142
+ * Detect if the primary pointer is fine (mouse/trackpad)
143
+ */
144
+ declare function pointerFine(): boolean;
137
145
  /**
138
146
  * Get the current screen reader mode (if detectable)
139
147
  * Note: This is not 100% reliable and should not be depended upon
@@ -223,6 +231,181 @@ declare function createComponentWarnings(componentName: string): {
223
231
  };
224
232
  };
225
233
 
234
+ /**
235
+ * Rich Text Editor — Engine-Agnostic Adapter Types
236
+ *
237
+ * These types define the contract between compa11y's RTE UI shell
238
+ * and any underlying editor engine (Lexical, ProseMirror/Tiptap, Slate, etc.).
239
+ *
240
+ * compa11y owns: accessible structure, toolbar, dialogs, keyboard contracts, dev warnings
241
+ * The adapter owns: editing behavior, selection, document model, serialization
242
+ */
243
+ /** Supported serialization formats */
244
+ type RTEFormat = 'html' | 'json' | 'markdown';
245
+ /** Value type — string for HTML/Markdown, object for JSON document */
246
+ type RTEValue = string | Record<string, unknown>;
247
+ /** Inline formatting marks */
248
+ type RTEMark = 'bold' | 'italic' | 'underline' | 'strikethrough' | 'code';
249
+ /** Block-level formatting types */
250
+ type RTEBlock = 'paragraph' | 'heading1' | 'heading2' | 'heading3' | 'heading4' | 'heading5' | 'heading6' | 'blockquote' | 'bulletList' | 'numberList' | 'codeBlock';
251
+ /** Current selection/formatting state — toolbar reads this to reflect pressed states */
252
+ interface RTESelectionState {
253
+ /** Whether the selection is collapsed (caret, no range) */
254
+ isCollapsed: boolean;
255
+ /** Active inline marks at cursor/selection */
256
+ marks: Partial<Record<RTEMark, boolean>>;
257
+ /** Current block type at cursor */
258
+ block: RTEBlock;
259
+ /** Whether undo is available */
260
+ canUndo: boolean;
261
+ /** Whether redo is available */
262
+ canRedo: boolean;
263
+ /** Link context at cursor, if inside a link */
264
+ link?: {
265
+ href: string;
266
+ text?: string;
267
+ } | null;
268
+ }
269
+ /** Default empty selection state */
270
+ declare const EMPTY_SELECTION_STATE: RTESelectionState;
271
+ /** Feature flags that control which toolbar controls are available */
272
+ interface RTEFeatures {
273
+ bold?: boolean;
274
+ italic?: boolean;
275
+ underline?: boolean;
276
+ strikethrough?: boolean;
277
+ headings?: boolean;
278
+ lists?: boolean;
279
+ link?: boolean;
280
+ code?: boolean;
281
+ blockquote?: boolean;
282
+ image?: boolean;
283
+ table?: boolean;
284
+ }
285
+ /** Default feature set — common formatting only */
286
+ declare const DEFAULT_RTE_FEATURES: RTEFeatures;
287
+ /** Options passed to the adapter when mounting the editor */
288
+ interface RTEMountOptions {
289
+ /** Whether the editor is read-only */
290
+ readOnly: boolean;
291
+ /** Whether the editor is disabled */
292
+ disabled: boolean;
293
+ /** Placeholder text */
294
+ placeholder?: string;
295
+ /** ID of the element labelling the editor */
296
+ ariaLabelledBy?: string;
297
+ /** ID(s) of the element(s) describing the editor */
298
+ ariaDescribedBy?: string;
299
+ /** Called when the editor content changes */
300
+ onChange: () => void;
301
+ /** Called when the selection/format state changes */
302
+ onSelectionChange: () => void;
303
+ /** Called when the editor receives focus */
304
+ onFocus?: () => void;
305
+ /** Called when the editor loses focus */
306
+ onBlur?: () => void;
307
+ }
308
+ /** Link insertion/edit options */
309
+ interface RTELinkOptions {
310
+ href: string;
311
+ text?: string;
312
+ }
313
+ /** Image insertion options */
314
+ interface RTEImageOptions {
315
+ src: string;
316
+ alt: string;
317
+ title?: string;
318
+ }
319
+ /** Table insertion options */
320
+ interface RTETableOptions {
321
+ rows: number;
322
+ cols: number;
323
+ }
324
+ /** Commands the adapter must implement */
325
+ interface RTECommands {
326
+ /** Focus the editor */
327
+ focus: () => void;
328
+ /** Undo last action */
329
+ undo: () => void;
330
+ /** Redo last undone action */
331
+ redo: () => void;
332
+ /** Toggle an inline mark (bold, italic, etc.) */
333
+ toggleMark: (mark: RTEMark) => void;
334
+ /** Set the current block type */
335
+ setBlock: (block: RTEBlock) => void;
336
+ /** Toggle bulleted list */
337
+ toggleBulletList: () => void;
338
+ /** Toggle numbered list */
339
+ toggleNumberList: () => void;
340
+ /** Indent current block */
341
+ indent: () => void;
342
+ /** Outdent current block */
343
+ outdent: () => void;
344
+ /** Insert or edit a link */
345
+ insertOrEditLink: (opts: RTELinkOptions) => void;
346
+ /** Remove the link at cursor */
347
+ removeLink: () => void;
348
+ /** Toggle code block */
349
+ toggleCodeBlock: () => void;
350
+ /** Insert an image (optional — adapter may not support) */
351
+ insertImage?: (opts: RTEImageOptions) => void;
352
+ /** Insert a table (optional — adapter may not support) */
353
+ insertTable?: (opts: RTETableOptions) => void;
354
+ /** Paste as plain text (optional) */
355
+ pasteAsPlainText?: () => void;
356
+ }
357
+ /** What the adapter actually supports at runtime */
358
+ interface RTECapabilities {
359
+ marks?: Partial<Record<RTEMark, boolean>>;
360
+ blocks?: Partial<Record<RTEBlock, boolean>>;
361
+ link?: boolean;
362
+ image?: boolean;
363
+ table?: boolean;
364
+ }
365
+ /**
366
+ * RTEAdapter — the contract between compa11y's RTE shell and an editor engine.
367
+ *
368
+ * Implement this interface for each engine:
369
+ * - @compa11y/rte-lexical
370
+ * - @compa11y/rte-tiptap (or rte-prosemirror)
371
+ *
372
+ * The adapter is responsible for all editing behavior.
373
+ * compa11y is responsible for the accessible UI shell around it.
374
+ */
375
+ interface RTEAdapter {
376
+ /** Mount the editor into a DOM element. Returns an unmount function. */
377
+ mount: (el: HTMLElement, opts: RTEMountOptions) => () => void;
378
+ /** Get the current selection/format state for toolbar UI */
379
+ getSelectionState: () => RTESelectionState;
380
+ /** Get the current value in the specified format */
381
+ getValue: (format: RTEFormat) => RTEValue;
382
+ /** Set the editor value from the specified format */
383
+ setValue: (value: RTEValue, format: RTEFormat) => void;
384
+ /** Whether the editor is empty (no meaningful content) */
385
+ isEmpty: () => boolean;
386
+ /** Get the plain text content (for validation, char count, etc.) */
387
+ getPlainText: () => string;
388
+ /** Get the character count */
389
+ getCharacterCount: () => number;
390
+ /** All editor commands (toggle marks, insert links, undo/redo, etc.) */
391
+ commands: RTECommands;
392
+ /** Runtime feature detection — what the adapter actually supports */
393
+ supports?: RTECapabilities;
394
+ /** Optional HTML sanitizer (required if adapter outputs HTML) */
395
+ sanitizeHtml?: (html: string) => string;
396
+ }
397
+ /** Configuration for creating an adapter */
398
+ interface RTEAdapterConfig {
399
+ /** Features to enable in the engine schema */
400
+ features?: RTEFeatures;
401
+ /** HTML sanitizer function */
402
+ sanitizeHtml?: (html: string) => string;
403
+ /** Custom configuration passed to the engine */
404
+ engineConfig?: Record<string, unknown>;
405
+ }
406
+ /** Factory function type for creating an adapter */
407
+ type RTEAdapterFactory = (config?: RTEAdapterConfig) => RTEAdapter;
408
+
226
409
  /**
227
410
  * @compa11y/core
228
411
  *
@@ -238,4 +421,4 @@ declare function createComponentWarnings(componentName: string): {
238
421
  */
239
422
  declare function initCompa11y(): () => void;
240
423
 
241
- export { DevWarning, DevWarningHandler, FOCUSABLE_SELECTORS, TABBABLE_SELECTORS, checks, clearWarnings, containsFocus, createComponentWarnings, createIdScope, createMediaQueryListener, generateId, generateIds, getFirstFocusable, getFocusableElements, getLastFocusable, getNextFocusable, getPreviousFocusable, getScreenReaderHints, getTabbableElements, initCompa11y, isAndroid, isBrowser, isFocusable, isIOS, isMac, isTabbable, isTouchDevice, isVisible, isWindows, isWithinContainer, prefersDarkMode, prefersHighContrast, prefersReducedMotion, resetIdCounter, resolveElement, setWarningHandler, warn };
424
+ export { DEFAULT_RTE_FEATURES, DevWarning, DevWarningHandler, EMPTY_SELECTION_STATE, FOCUSABLE_SELECTORS, type RTEAdapter, type RTEAdapterConfig, type RTEAdapterFactory, type RTEBlock, type RTECapabilities, type RTECommands, type RTEFeatures, type RTEFormat, type RTEImageOptions, type RTELinkOptions, type RTEMark, type RTEMountOptions, type RTESelectionState, type RTETableOptions, type RTEValue, TABBABLE_SELECTORS, checks, clearWarnings, containsFocus, createComponentWarnings, createIdScope, createMediaQueryListener, generateId, generateIds, getFirstFocusable, getFocusableElements, getLastFocusable, getNextFocusable, getPreviousFocusable, getScreenReaderHints, getTabbableElements, initCompa11y, isAndroid, isBrowser, isFocusable, isIOS, isMac, isTabbable, isTouchDevice, isVisible, isWindows, isWithinContainer, pointerCoarse, pointerFine, prefersDarkMode, prefersHighContrast, prefersReducedMotion, resetIdCounter, resolveElement, setWarningHandler, warn };
package/dist/index.d.ts CHANGED
@@ -134,6 +134,14 @@ declare function prefersHighContrast(): boolean;
134
134
  * Detect if user prefers dark color scheme
135
135
  */
136
136
  declare function prefersDarkMode(): boolean;
137
+ /**
138
+ * Detect if the primary pointer is coarse (touch/stylus)
139
+ */
140
+ declare function pointerCoarse(): boolean;
141
+ /**
142
+ * Detect if the primary pointer is fine (mouse/trackpad)
143
+ */
144
+ declare function pointerFine(): boolean;
137
145
  /**
138
146
  * Get the current screen reader mode (if detectable)
139
147
  * Note: This is not 100% reliable and should not be depended upon
@@ -223,6 +231,181 @@ declare function createComponentWarnings(componentName: string): {
223
231
  };
224
232
  };
225
233
 
234
+ /**
235
+ * Rich Text Editor — Engine-Agnostic Adapter Types
236
+ *
237
+ * These types define the contract between compa11y's RTE UI shell
238
+ * and any underlying editor engine (Lexical, ProseMirror/Tiptap, Slate, etc.).
239
+ *
240
+ * compa11y owns: accessible structure, toolbar, dialogs, keyboard contracts, dev warnings
241
+ * The adapter owns: editing behavior, selection, document model, serialization
242
+ */
243
+ /** Supported serialization formats */
244
+ type RTEFormat = 'html' | 'json' | 'markdown';
245
+ /** Value type — string for HTML/Markdown, object for JSON document */
246
+ type RTEValue = string | Record<string, unknown>;
247
+ /** Inline formatting marks */
248
+ type RTEMark = 'bold' | 'italic' | 'underline' | 'strikethrough' | 'code';
249
+ /** Block-level formatting types */
250
+ type RTEBlock = 'paragraph' | 'heading1' | 'heading2' | 'heading3' | 'heading4' | 'heading5' | 'heading6' | 'blockquote' | 'bulletList' | 'numberList' | 'codeBlock';
251
+ /** Current selection/formatting state — toolbar reads this to reflect pressed states */
252
+ interface RTESelectionState {
253
+ /** Whether the selection is collapsed (caret, no range) */
254
+ isCollapsed: boolean;
255
+ /** Active inline marks at cursor/selection */
256
+ marks: Partial<Record<RTEMark, boolean>>;
257
+ /** Current block type at cursor */
258
+ block: RTEBlock;
259
+ /** Whether undo is available */
260
+ canUndo: boolean;
261
+ /** Whether redo is available */
262
+ canRedo: boolean;
263
+ /** Link context at cursor, if inside a link */
264
+ link?: {
265
+ href: string;
266
+ text?: string;
267
+ } | null;
268
+ }
269
+ /** Default empty selection state */
270
+ declare const EMPTY_SELECTION_STATE: RTESelectionState;
271
+ /** Feature flags that control which toolbar controls are available */
272
+ interface RTEFeatures {
273
+ bold?: boolean;
274
+ italic?: boolean;
275
+ underline?: boolean;
276
+ strikethrough?: boolean;
277
+ headings?: boolean;
278
+ lists?: boolean;
279
+ link?: boolean;
280
+ code?: boolean;
281
+ blockquote?: boolean;
282
+ image?: boolean;
283
+ table?: boolean;
284
+ }
285
+ /** Default feature set — common formatting only */
286
+ declare const DEFAULT_RTE_FEATURES: RTEFeatures;
287
+ /** Options passed to the adapter when mounting the editor */
288
+ interface RTEMountOptions {
289
+ /** Whether the editor is read-only */
290
+ readOnly: boolean;
291
+ /** Whether the editor is disabled */
292
+ disabled: boolean;
293
+ /** Placeholder text */
294
+ placeholder?: string;
295
+ /** ID of the element labelling the editor */
296
+ ariaLabelledBy?: string;
297
+ /** ID(s) of the element(s) describing the editor */
298
+ ariaDescribedBy?: string;
299
+ /** Called when the editor content changes */
300
+ onChange: () => void;
301
+ /** Called when the selection/format state changes */
302
+ onSelectionChange: () => void;
303
+ /** Called when the editor receives focus */
304
+ onFocus?: () => void;
305
+ /** Called when the editor loses focus */
306
+ onBlur?: () => void;
307
+ }
308
+ /** Link insertion/edit options */
309
+ interface RTELinkOptions {
310
+ href: string;
311
+ text?: string;
312
+ }
313
+ /** Image insertion options */
314
+ interface RTEImageOptions {
315
+ src: string;
316
+ alt: string;
317
+ title?: string;
318
+ }
319
+ /** Table insertion options */
320
+ interface RTETableOptions {
321
+ rows: number;
322
+ cols: number;
323
+ }
324
+ /** Commands the adapter must implement */
325
+ interface RTECommands {
326
+ /** Focus the editor */
327
+ focus: () => void;
328
+ /** Undo last action */
329
+ undo: () => void;
330
+ /** Redo last undone action */
331
+ redo: () => void;
332
+ /** Toggle an inline mark (bold, italic, etc.) */
333
+ toggleMark: (mark: RTEMark) => void;
334
+ /** Set the current block type */
335
+ setBlock: (block: RTEBlock) => void;
336
+ /** Toggle bulleted list */
337
+ toggleBulletList: () => void;
338
+ /** Toggle numbered list */
339
+ toggleNumberList: () => void;
340
+ /** Indent current block */
341
+ indent: () => void;
342
+ /** Outdent current block */
343
+ outdent: () => void;
344
+ /** Insert or edit a link */
345
+ insertOrEditLink: (opts: RTELinkOptions) => void;
346
+ /** Remove the link at cursor */
347
+ removeLink: () => void;
348
+ /** Toggle code block */
349
+ toggleCodeBlock: () => void;
350
+ /** Insert an image (optional — adapter may not support) */
351
+ insertImage?: (opts: RTEImageOptions) => void;
352
+ /** Insert a table (optional — adapter may not support) */
353
+ insertTable?: (opts: RTETableOptions) => void;
354
+ /** Paste as plain text (optional) */
355
+ pasteAsPlainText?: () => void;
356
+ }
357
+ /** What the adapter actually supports at runtime */
358
+ interface RTECapabilities {
359
+ marks?: Partial<Record<RTEMark, boolean>>;
360
+ blocks?: Partial<Record<RTEBlock, boolean>>;
361
+ link?: boolean;
362
+ image?: boolean;
363
+ table?: boolean;
364
+ }
365
+ /**
366
+ * RTEAdapter — the contract between compa11y's RTE shell and an editor engine.
367
+ *
368
+ * Implement this interface for each engine:
369
+ * - @compa11y/rte-lexical
370
+ * - @compa11y/rte-tiptap (or rte-prosemirror)
371
+ *
372
+ * The adapter is responsible for all editing behavior.
373
+ * compa11y is responsible for the accessible UI shell around it.
374
+ */
375
+ interface RTEAdapter {
376
+ /** Mount the editor into a DOM element. Returns an unmount function. */
377
+ mount: (el: HTMLElement, opts: RTEMountOptions) => () => void;
378
+ /** Get the current selection/format state for toolbar UI */
379
+ getSelectionState: () => RTESelectionState;
380
+ /** Get the current value in the specified format */
381
+ getValue: (format: RTEFormat) => RTEValue;
382
+ /** Set the editor value from the specified format */
383
+ setValue: (value: RTEValue, format: RTEFormat) => void;
384
+ /** Whether the editor is empty (no meaningful content) */
385
+ isEmpty: () => boolean;
386
+ /** Get the plain text content (for validation, char count, etc.) */
387
+ getPlainText: () => string;
388
+ /** Get the character count */
389
+ getCharacterCount: () => number;
390
+ /** All editor commands (toggle marks, insert links, undo/redo, etc.) */
391
+ commands: RTECommands;
392
+ /** Runtime feature detection — what the adapter actually supports */
393
+ supports?: RTECapabilities;
394
+ /** Optional HTML sanitizer (required if adapter outputs HTML) */
395
+ sanitizeHtml?: (html: string) => string;
396
+ }
397
+ /** Configuration for creating an adapter */
398
+ interface RTEAdapterConfig {
399
+ /** Features to enable in the engine schema */
400
+ features?: RTEFeatures;
401
+ /** HTML sanitizer function */
402
+ sanitizeHtml?: (html: string) => string;
403
+ /** Custom configuration passed to the engine */
404
+ engineConfig?: Record<string, unknown>;
405
+ }
406
+ /** Factory function type for creating an adapter */
407
+ type RTEAdapterFactory = (config?: RTEAdapterConfig) => RTEAdapter;
408
+
226
409
  /**
227
410
  * @compa11y/core
228
411
  *
@@ -238,4 +421,4 @@ declare function createComponentWarnings(componentName: string): {
238
421
  */
239
422
  declare function initCompa11y(): () => void;
240
423
 
241
- export { DevWarning, DevWarningHandler, FOCUSABLE_SELECTORS, TABBABLE_SELECTORS, checks, clearWarnings, containsFocus, createComponentWarnings, createIdScope, createMediaQueryListener, generateId, generateIds, getFirstFocusable, getFocusableElements, getLastFocusable, getNextFocusable, getPreviousFocusable, getScreenReaderHints, getTabbableElements, initCompa11y, isAndroid, isBrowser, isFocusable, isIOS, isMac, isTabbable, isTouchDevice, isVisible, isWindows, isWithinContainer, prefersDarkMode, prefersHighContrast, prefersReducedMotion, resetIdCounter, resolveElement, setWarningHandler, warn };
424
+ export { DEFAULT_RTE_FEATURES, DevWarning, DevWarningHandler, EMPTY_SELECTION_STATE, FOCUSABLE_SELECTORS, type RTEAdapter, type RTEAdapterConfig, type RTEAdapterFactory, type RTEBlock, type RTECapabilities, type RTECommands, type RTEFeatures, type RTEFormat, type RTEImageOptions, type RTELinkOptions, type RTEMark, type RTEMountOptions, type RTESelectionState, type RTETableOptions, type RTEValue, TABBABLE_SELECTORS, checks, clearWarnings, containsFocus, createComponentWarnings, createIdScope, createMediaQueryListener, generateId, generateIds, getFirstFocusable, getFocusableElements, getLastFocusable, getNextFocusable, getPreviousFocusable, getScreenReaderHints, getTabbableElements, initCompa11y, isAndroid, isBrowser, isFocusable, isIOS, isMac, isTabbable, isTouchDevice, isVisible, isWindows, isWithinContainer, pointerCoarse, pointerFine, prefersDarkMode, prefersHighContrast, prefersReducedMotion, resetIdCounter, resolveElement, setWarningHandler, warn };
package/dist/index.js CHANGED
@@ -1,3 +1 @@
1
- export{a as FOCUSABLE_SELECTORS,b as TABBABLE_SELECTORS,j as containsFocus,A as createFocusReturn,x as createFocusScope,o as createFocusTrap,y as createRovingTabindex,z as findFocusNeighbor,w as focusWithVisibleRing,p as getActiveFocusTrap,h as getFirstFocusable,f as getFocusableElements,u as getLastFocusSource,i as getLastFocusable,k as getNextFocusable,l as getPreviousFocusable,g as getTabbableElements,q as hasFocusTrap,t as hasVisibleFocus,r as initFocusVisible,s as isFocusVisible,d as isFocusable,e as isTabbable,c as isVisible,m as isWithinContainer,n as resolveElement,v as setFocusVisible}from'./chunk-7RLRK53P.js';export{d as KeyboardPatterns,c as createKeyboardManager,e as createTypeAhead,b as getKeyCombo,a as normalizeKey}from'./chunk-RE4QIUWR.js';export{b as announce,d as announceAssertive,i as announceError,c as announcePolite,j as announceProgress,h as announceStatus,e as clearAnnouncements,g as createAnnouncer,a as initAnnouncer,f as queueAnnouncement}from'./chunk-ZAQMM5TA.js';export{k as createMediaQueryListener,j as getScreenReaderHints,d as isAndroid,a as isBrowser,c as isIOS,b as isMac,f as isTouchDevice,e as isWindows,i as prefersDarkMode,h as prefersHighContrast,g as prefersReducedMotion}from'./chunk-C3VZQUKG.js';import {d as d$1}from'./chunk-TGXWODB3.js';export{a as aria,b as buildAriaProps,d as hasAccessibleName,c as mergeAriaIds}from'./chunk-TGXWODB3.js';var g=0,d="compa11y";function u(e){let n=++g;return e?`${d}-${e}-${n}`:`${d}-${n}`}function $e(e,n){let r=u(n),t={};for(let o of e)t[o]=`${r}-${o}`;return t}function we(){g=0;}function Ae(e){let n=u(e);return {id:n,generate:r=>`${n}-${r}`,generateMultiple:r=>{let t={};for(let o of r)t[o]=`${n}-${o}`;return t}}}var a=null,l=new Set;function p(){return typeof process<"u"&&process.env?.NODE_ENV!=="production"}function b(e){a=e;}function f(e){return `${e.component}:${e.message}`}function i(e){if(!p())return;let n=f(e);if(l.has(n))return;if(l.add(n),a){a(e);return}let r=`[compa11y/${e.component}]`,t=m(e.type),o=e.suggestion?`${e.message}
2
-
3
- \u{1F4A1} Suggestion: ${e.suggestion}`:e.message;switch(e.type){case "error":console.error(`%c${r}%c ${o}`,t,"");break;case "warning":console.warn(`%c${r}%c ${o}`,t,"");break;case "info":console.info(`%c${r}%c ${o}`,t,"");break}e.element&&console.log("Element:",e.element);}function m(e){switch(e){case "error":return "background: #ff5555; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "warning":return "background: #ffaa00; color: black; padding: 2px 4px; border-radius: 2px; font-weight: bold;";case "info":return "background: #5555ff; color: white; padding: 2px 4px; border-radius: 2px; font-weight: bold;"}}function x(){l.clear();}var s={accessibleLabel(e,n,r="aria-label"){e&&(d$1(e)||i({type:"error",component:n,message:"Missing accessible label. Screen reader users will not be able to understand this element.",suggestion:`Add ${r}, aria-labelledby, or visible text content.`,element:e}));},requiredProp(e,n,r){(e==null||e==="")&&i({type:"error",component:r,message:`Missing required prop "${n}".`,suggestion:`Provide a value for the "${n}" prop.`});},validRole(e,n,r){if(!e)return;new Set(["alert","alertdialog","application","article","banner","button","cell","columnheader","combobox","complementary","contentinfo","definition","dialog","directory","document","feed","figure","form","grid","gridcell","group","heading","img","link","list","listbox","listitem","log","main","marquee","math","menu","menubar","menuitem","navigation","none","note","option","presentation","progressbar","region","row","rowgroup","rowheader","scrollbar","search","searchbox","separator","slider","spinbutton","status","switch","tab","table","tablist","tabpanel","term","textbox","timer","toolbar","tooltip","tree","treegrid","treeitem"]).has(e)||i({type:"warning",component:n,message:`Invalid ARIA role "${e}".`,suggestion:"Use a valid ARIA role from the WAI-ARIA specification.",element:r});},keyboardAccessible(e,n,r){if(e&&r.onClick&&!r.onKeyDown){let t=e.tagName.toLowerCase(),o=e.getAttribute("role");if(["button","a","input","select","textarea"].includes(t))return;o&&["button","link","menuitem","option","tab"].includes(o)&&i({type:"warning",component:n,message:"Element has onClick but no onKeyDown handler.",suggestion:"Add keyboard event handling for Enter and Space keys.",element:e});}},tabIndex(e,n,r){e!==void 0&&e>0&&i({type:"warning",component:n,message:`Positive tabIndex (${e}) disrupts natural tab order.`,suggestion:"Use tabIndex={0} or tabIndex={-1} instead. Rely on DOM order for tab sequence.",element:r});},dialogAutoFocus(e,n){e||i({type:"info",component:n,message:"No initial focus element specified for dialog.",suggestion:"Consider setting initialFocus to guide keyboard users."});},formLabel(e,n,r){if(!e)return;n||e.getAttribute("aria-label")||e.getAttribute("aria-labelledby")||e.labels?.length||i({type:"error",component:r,message:"Form input is missing an accessible label.",suggestion:"Add a <label>, aria-label, or aria-labelledby.",element:e});},imageAlt(e,n){if(!e||e.tagName!=="IMG")return;let r=e.getAttribute("alt"),t=e.getAttribute("role");r===null&&t!=="presentation"&&t!=="none"&&i({type:"error",component:n,message:"Image is missing alt attribute.",suggestion:'Add alt="" for decorative images or descriptive alt text for meaningful images.',element:e});}};function y(e){return {error:(n,r,t)=>i({type:"error",component:e,message:n,suggestion:r,element:t}),warning:(n,r,t)=>i({type:"warning",component:e,message:n,suggestion:r,element:t}),info:(n,r,t)=>i({type:"info",component:e,message:n,suggestion:r,element:t}),checks:{accessibleLabel:(n,r)=>s.accessibleLabel(n,e,r),requiredProp:(n,r)=>s.requiredProp(n,r,e),keyboardAccessible:(n,r)=>s.keyboardAccessible(n,e,r),tabIndex:(n,r)=>s.tabIndex(n,e,r)}}}function We(){let e=[];return import('./focus/index.js').then(({initFocusVisible:n})=>{e.push(n());}),import('./announcer/index.js').then(({initAnnouncer:n})=>{e.push(n());}),()=>{e.forEach(n=>n());}}export{s as checks,x as clearWarnings,y as createComponentWarnings,Ae as createIdScope,u as generateId,$e as generateIds,We as initCompa11y,we as resetIdCounter,b as setWarningHandler,i as warn};
1
+ export{a as FOCUSABLE_SELECTORS,b as TABBABLE_SELECTORS,r as checks,q as clearWarnings,j as containsFocus,s as createComponentWarnings,F as createFocusReturn,C as createFocusScope,t as createFocusTrap,D as createRovingTabindex,E as findFocusNeighbor,B as focusWithVisibleRing,u as getActiveFocusTrap,h as getFirstFocusable,f as getFocusableElements,z as getLastFocusSource,i as getLastFocusable,k as getNextFocusable,l as getPreviousFocusable,g as getTabbableElements,v as hasFocusTrap,y as hasVisibleFocus,w as initFocusVisible,x as isFocusVisible,d as isFocusable,e as isTabbable,c as isVisible,m as isWithinContainer,n as resolveElement,A as setFocusVisible,o as setWarningHandler,p as warn}from'./chunk-UV66DEGV.js';export{d as KeyboardPatterns,c as createKeyboardManager,e as createTypeAhead,b as getKeyCombo,a as normalizeKey}from'./chunk-U7FU44ZV.js';export{b as announce,d as announceAssertive,i as announceError,c as announcePolite,j as announceProgress,h as announceStatus,e as clearAnnouncements,g as createAnnouncer,a as initAnnouncer,f as queueAnnouncement}from'./chunk-RW6UYIXK.js';export{m as createMediaQueryListener,l as getScreenReaderHints,d as isAndroid,a as isBrowser,c as isIOS,b as isMac,f as isTouchDevice,e as isWindows,j as pointerCoarse,k as pointerFine,i as prefersDarkMode,h as prefersHighContrast,g as prefersReducedMotion}from'./chunk-25OQO77R.js';import'./chunk-B3F6LTF6.js';export{a as aria,b as buildAriaProps,d as hasAccessibleName,c as mergeAriaIds}from'./chunk-5LRBCHHZ.js';var a=0,i="compa11y";function s(o){let e=++a;return o?`${i}-${o}-${e}`:`${i}-${e}`}function Ee(o,e){let t=s(e),r={};for(let n of o)r[n]=`${t}-${n}`;return r}function fe(){a=0;}function ke(o){let e=s(o);return {id:e,generate:t=>`${e}-${t}`,generateMultiple:t=>{let r={};for(let n of t)r[n]=`${e}-${n}`;return r}}}var Ce={isCollapsed:true,marks:{},block:"paragraph",canUndo:false,canRedo:false,link:null},ye={bold:true,italic:true,underline:true,strikethrough:false,headings:true,lists:true,link:true,code:true,blockquote:true,image:false,table:false};function Le(){let o=[];return import('./focus/index.js').then(({initFocusVisible:e})=>{o.push(e());}),import('./announcer/index.js').then(({initAnnouncer:e})=>{o.push(e());}),()=>{o.forEach(e=>e());}}export{ye as DEFAULT_RTE_FEATURES,Ce as EMPTY_SELECTION_STATE,ke as createIdScope,s as generateId,Ee as generateIds,Le as initCompa11y,fe as resetIdCounter};
@@ -1 +1 @@
1
- 'use strict';var chunkEM45V5TK_cjs=require('../chunk-EM45V5TK.cjs');Object.defineProperty(exports,"KeyboardPatterns",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.d}});Object.defineProperty(exports,"createKeyboardManager",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.c}});Object.defineProperty(exports,"createTypeAhead",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.e}});Object.defineProperty(exports,"getKeyCombo",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.b}});Object.defineProperty(exports,"normalizeKey",{enumerable:true,get:function(){return chunkEM45V5TK_cjs.a}});
1
+ 'use strict';var chunk5OQKJSL6_cjs=require('../chunk-5OQKJSL6.cjs');Object.defineProperty(exports,"KeyboardPatterns",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.d}});Object.defineProperty(exports,"createKeyboardManager",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.c}});Object.defineProperty(exports,"createTypeAhead",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.e}});Object.defineProperty(exports,"getKeyCombo",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.b}});Object.defineProperty(exports,"normalizeKey",{enumerable:true,get:function(){return chunk5OQKJSL6_cjs.a}});
@@ -1 +1 @@
1
- export{d as KeyboardPatterns,c as createKeyboardManager,e as createTypeAhead,b as getKeyCombo,a as normalizeKey}from'../chunk-RE4QIUWR.js';
1
+ export{d as KeyboardPatterns,c as createKeyboardManager,e as createTypeAhead,b as getKeyCombo,a as normalizeKey}from'../chunk-U7FU44ZV.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@compa11y/core",
3
- "version": "0.2.1",
3
+ "version": "0.2.3",
4
4
  "description": "Framework-agnostic accessibility primitives",
5
5
  "author": "Ivan Trajkovski",
6
6
  "license": "MIT",
@@ -1 +0,0 @@
1
- 'use strict';function e(){return typeof window<"u"&&typeof document<"u"}function s(){return e()?/Mac|iPod|iPhone|iPad/.test(navigator.platform):false}function c(){return e()?/iPod|iPhone|iPad/.test(navigator.platform)||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1:false}function d(){return e()?/Android/.test(navigator.userAgent):false}function f(){return e()?/Win/.test(navigator.platform):false}function u(){return e()?"ontouchstart"in window||navigator.maxTouchPoints>0:false}function l(){return e()?window.matchMedia("(prefers-reduced-motion: reduce)").matches:false}function m(){return e()?window.matchMedia("(prefers-contrast: more)").matches||window.matchMedia("(-ms-high-contrast: active)").matches:false}function h(){return e()?window.matchMedia("(prefers-color-scheme: dark)").matches:false}function p(){if(!e())return {possibleScreenReader:false,forcedColors:false};let n=window.matchMedia("(forced-colors: active)").matches;return {possibleScreenReader:n,forcedColors:n}}function v(n,o){if(!e())return ()=>{};let r=window.matchMedia(n);if(o(r.matches),r.addEventListener){let a=i=>o(i.matches);return r.addEventListener("change",a),()=>r.removeEventListener("change",a)}let t=()=>o(r.matches);return r.addListener(t),()=>r.removeListener(t)}exports.a=e;exports.b=s;exports.c=c;exports.d=d;exports.e=f;exports.f=u;exports.g=l;exports.h=m;exports.i=h;exports.j=p;exports.k=v;
@@ -1 +0,0 @@
1
- import {a}from'./chunk-C3VZQUKG.js';var D=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]',"audio[controls]","video[controls]","details > summary:first-of-type","iframe"].join(","),K=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])','[contenteditable="true"]:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','details > summary:first-of-type:not([tabindex="-1"])','iframe:not([tabindex="-1"])'].join(",");function U(e){if(!(e instanceof HTMLElement)||e.hidden||e.style.display==="none"||e.style.visibility==="hidden")return false;let t=window.getComputedStyle(e);return !(t.display==="none"||t.visibility==="hidden"||!e.isConnected)}function V(e){return !(!(e instanceof HTMLElement)||!U(e)||!e.matches(D)||e.closest("[inert]"))}function I(e){return !V(e)||e.tabIndex<0?false:e.matches(K)}function oe(e){return Array.from(e.querySelectorAll(D)).filter(V)}function T(e){return Array.from(e.querySelectorAll(K)).filter(I).sort((u,r)=>{let n=Math.max(0,u.tabIndex),i=Math.max(0,r.tabIndex);return n===0&&i===0?0:n===0?1:i===0?-1:n-i})}function A(e){return T(e)[0]??null}function re(e){let t=T(e);return t[t.length-1]??null}function P(e){let t=document.activeElement;return t!==null&&e.contains(t)}function N(e,t,a=true){let u=T(e),r=u.indexOf(t);if(r===-1)return u[0]??null;let n=r+1;return n<u.length?u[n]:a?u[0]??null:null}function C(e,t,a=true){let u=T(e),r=u.indexOf(t);if(r===-1)return u[u.length-1]??null;let n=r-1;return n>=0?u[n]:a?u[u.length-1]??null:null}function ie(e,t){return t.contains(e)}function q(e,t=document.body){return e?typeof e=="string"?t.querySelector(e):typeof e=="function"?e():e:null}var F=[];function _(e,t={}){let{initialFocus:a,returnFocus:u=true,clickOutsideDeactivates:r=false,escapeDeactivates:n=true,onDeactivate:i,onEscapeFocus:c}=t,o=false,m=false,f=null;function h(l){m||!o||(l.key==="Tab"?y(l):l.key==="Escape"&&n&&(l.preventDefault(),l.stopPropagation(),v()));}function y(l){let E=T(e);if(E.length===0){l.preventDefault();return}let w=E[0],g=E[E.length-1],S=document.activeElement;l.shiftKey?(S===w||!e.contains(S))&&(l.preventDefault(),g.focus()):(S===g||!e.contains(S))&&(l.preventDefault(),w.focus());}function p(l){if(m||!o)return;let E=l.target;e.contains(E)||(c?.(E),A(e)?.focus());}function d(l){if(m||!o)return;let E=l.target;r&&!e.contains(E)&&v();}function b(){if(!o){f=document.activeElement,F.push(k);for(let l=0;l<F.length-1;l++)F[l].pause();document.addEventListener("keydown",h,true),document.addEventListener("focusin",p,true),document.addEventListener("click",d,true),o=true,requestAnimationFrame(()=>{if(!o)return;let l=q(a,e);if(l)l.focus();else {let E=A(e);E?E.focus():(e.setAttribute("tabindex","-1"),e.focus());}});}}function s(l){if(!o)return;document.removeEventListener("keydown",h,true),document.removeEventListener("focusin",p,true),document.removeEventListener("click",d,true),o=false,m=false;let E=F.indexOf(k);if(E>-1&&F.splice(E,1),F[F.length-1]?.unpause(),u&&f){let g=typeof u=="boolean"?f:u;requestAnimationFrame(()=>{g&&"focus"in g&&g.focus();});}l&&i?.();}function v(){s(true);}function L(){s(false);}function M(){!o||m||(m=true);}function H(){!o||!m||(m=false,P(e)||A(e)?.focus());}let k={activate:b,deactivate:v,destroy:L,pause:M,unpause:H,isActive:()=>o,isPaused:()=>m};return k}function z(){return F[F.length-1]??null}function W(){return F.length>0}var x={hadKeyboardEvent:true,isPointerInput:false,lastFocusSource:"unknown"},O=false,j=new Set(["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"," ","Home","End","PageUp","PageDown","Escape"]);function G(){if(!a()||O)return ()=>{};O=true;function e(n){j.has(n.key)&&(x.hadKeyboardEvent=true,x.isPointerInput=false,x.lastFocusSource="keyboard");}function t(n){x.isPointerInput=true,x.hadKeyboardEvent=false,x.lastFocusSource="pointerType"in n&&n.pointerType==="touch"?"touch":"mouse";}function a$1(n){let i=n.target;i instanceof HTMLElement&&(x.hadKeyboardEvent||Y(i))&&(i.dataset.compa11yFocusVisible="true");}function u(n){let i=n.target;i instanceof HTMLElement&&delete i.dataset.compa11yFocusVisible;}function r(){document.visibilityState==="hidden"&&(x.hadKeyboardEvent=true);}return document.addEventListener("keydown",e,true),document.addEventListener("mousedown",t,true),document.addEventListener("pointerdown",t,true),document.addEventListener("focus",a$1,true),document.addEventListener("blur",u,true),document.addEventListener("visibilitychange",r,true),()=>{document.removeEventListener("keydown",e,true),document.removeEventListener("mousedown",t,true),document.removeEventListener("pointerdown",t,true),document.removeEventListener("focus",a$1,true),document.removeEventListener("blur",u,true),document.removeEventListener("visibilitychange",r,true),O=false;}}function Y(e){let t=e.tagName.toLowerCase(),a=e.getAttribute("type")?.toLowerCase();return !!(t==="input"&&(!a||a==="text"||a==="email"||a==="password"||a==="search"||a==="tel"||a==="url"||a==="number")||t==="textarea"||e.isContentEditable)}function J(){return x.hadKeyboardEvent}function Q(e){return e.dataset.compa11yFocusVisible==="true"}function X(){return x.lastFocusSource}function Z(e,t){t?e.dataset.compa11yFocusVisible="true":delete e.dataset.compa11yFocusVisible;}function $(e,t){x.hadKeyboardEvent=true,x.lastFocusSource="keyboard",e.focus(t);}function ee(e,t={}){let{contain:a=false,restoreFocus:u=false,autoFocus:r=false}=t,n=null,i=false;u&&(n=document.activeElement);function c(){return i?[]:T(e)}function o(){let s=document.activeElement;return s&&e.contains(s)?s:null}function m(){if(i)return;c()[0]?.focus();}function f(){if(i)return;let s=c();s[s.length-1]?.focus();}function h({wrap:s=true}={}){if(i)return;let v=o();if(!v){m();return}N(e,v,s)?.focus();}function y({wrap:s=true}={}){if(i)return;let v=o();if(!v){f();return}C(e,v,s)?.focus();}function p(s){if(i)return;c()[s]?.focus();}function d(s){if(!(i||!a)&&s.key==="Tab"){let v=c();if(v.length===0){s.preventDefault();return}let L=v[0],M=v[v.length-1],H=o();s.shiftKey&&H===L?(s.preventDefault(),M.focus()):!s.shiftKey&&H===M&&(s.preventDefault(),L.focus());}}function b(){i||(i=true,document.removeEventListener("keydown",d,true),u&&n&&n.focus());}return a&&document.addEventListener("keydown",d,true),r&&requestAnimationFrame(()=>{i||m();}),{focusFirst:m,focusLast:f,focusNext:h,focusPrevious:y,focusAt:p,getFocused:o,getElements:c,destroy:b}}function te(e,t,a={}){let{initialIndex:u=0,orientation:r="both",wrap:n=true,onSelectionChange:i}=a,c=[],o=u;function m(){c=Array.from(e.querySelectorAll(t)),c.forEach((p,d)=>{p.setAttribute("tabindex",d===o?"0":"-1");});}function f(p){if(c.length===0)return;let d=p;d<0?d=n?c.length-1:0:d>=c.length&&(d=n?0:c.length-1);let b=c[o],s=c[d];b&&b.setAttribute("tabindex","-1"),s&&(s.setAttribute("tabindex","0"),s.focus(),i?.(d,s)),o=d;}function h(p){let d=p.target;if(!c.includes(d))return;let b=false;switch(p.key){case "ArrowRight":(r==="horizontal"||r==="both")&&(f(o+1),b=true);break;case "ArrowLeft":(r==="horizontal"||r==="both")&&(f(o-1),b=true);break;case "ArrowDown":(r==="vertical"||r==="both")&&(f(o+1),b=true);break;case "ArrowUp":(r==="vertical"||r==="both")&&(f(o-1),b=true);break;case "Home":f(0),b=true;break;case "End":f(c.length-1),b=true;break}b&&(p.preventDefault(),p.stopPropagation());}function y(p){let d=p.target,b=c.indexOf(d);if(b!==-1&&b!==o){let s=c[o];s&&s.setAttribute("tabindex","-1"),d.setAttribute("tabindex","0"),o=b;}}return m(),e.addEventListener("keydown",h),e.addEventListener("focusin",y),{next:()=>f(o+1),previous:()=>f(o-1),first:()=>f(0),last:()=>f(c.length-1),goto:f,getIndex:()=>o,update:m,destroy:()=>{e.removeEventListener("keydown",h),e.removeEventListener("focusin",y);}}}function B(e,t={}){let{scope:a=e.parentElement??document.body,prefer:u="previous"}=t,r=T(a),n=r.indexOf(e);n===-1&&(n=r.findIndex(f=>e.compareDocumentPosition(f)&Node.DOCUMENT_POSITION_FOLLOWING),n===-1&&(n=r.length));let i=n-1,c=n+1,o=i>=0&&r[i]!==e?r[i]:null,m=c<r.length&&r[c]!==e?r[c]:null;return u==="previous"?o??m:m??o}function ne(e){let t=e??null;function a(n){t=n??document.activeElement??null;}function u(n={}){let{fallback:i,prefer:c="previous"}=n;if(!t){i?.focus();return}if(t.isConnected&&I(t)){t.focus(),t=null;return}if(t.isConnected){let o=B(t,{prefer:c});if(o){o.focus(),t=null;return}}i&&i.focus(),t=null;}function r(){t=null;}return {get element(){return t},save:a,return:u,clear:r}}export{ne as A,D as a,K as b,U as c,V as d,I as e,oe as f,T as g,A as h,re as i,P as j,N as k,C as l,ie as m,q as n,_ as o,z as p,W as q,G as r,J as s,Q as t,X as u,Z as v,$ as w,ee as x,te as y,B as z};
@@ -1 +0,0 @@
1
- 'use strict';var chunk7BL2ABLF_cjs=require('./chunk-7BL2ABLF.cjs');var D=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])",'[tabindex]:not([tabindex="-1"])','[contenteditable="true"]',"audio[controls]","video[controls]","details > summary:first-of-type","iframe"].join(","),K=['a[href]:not([tabindex="-1"])','area[href]:not([tabindex="-1"])','button:not([disabled]):not([tabindex="-1"])','input:not([disabled]):not([type="hidden"]):not([tabindex="-1"])','select:not([disabled]):not([tabindex="-1"])','textarea:not([disabled]):not([tabindex="-1"])','[tabindex]:not([tabindex="-1"])','[contenteditable="true"]:not([tabindex="-1"])','audio[controls]:not([tabindex="-1"])','video[controls]:not([tabindex="-1"])','details > summary:first-of-type:not([tabindex="-1"])','iframe:not([tabindex="-1"])'].join(",");function U(e){if(!(e instanceof HTMLElement)||e.hidden||e.style.display==="none"||e.style.visibility==="hidden")return false;let t=window.getComputedStyle(e);return !(t.display==="none"||t.visibility==="hidden"||!e.isConnected)}function V(e){return !(!(e instanceof HTMLElement)||!U(e)||!e.matches(D)||e.closest("[inert]"))}function I(e){return !V(e)||e.tabIndex<0?false:e.matches(K)}function oe(e){return Array.from(e.querySelectorAll(D)).filter(V)}function T(e){return Array.from(e.querySelectorAll(K)).filter(I).sort((u,r)=>{let n=Math.max(0,u.tabIndex),i=Math.max(0,r.tabIndex);return n===0&&i===0?0:n===0?1:i===0?-1:n-i})}function A(e){return T(e)[0]??null}function re(e){let t=T(e);return t[t.length-1]??null}function P(e){let t=document.activeElement;return t!==null&&e.contains(t)}function N(e,t,a=true){let u=T(e),r=u.indexOf(t);if(r===-1)return u[0]??null;let n=r+1;return n<u.length?u[n]:a?u[0]??null:null}function C(e,t,a=true){let u=T(e),r=u.indexOf(t);if(r===-1)return u[u.length-1]??null;let n=r-1;return n>=0?u[n]:a?u[u.length-1]??null:null}function ie(e,t){return t.contains(e)}function q(e,t=document.body){return e?typeof e=="string"?t.querySelector(e):typeof e=="function"?e():e:null}var F=[];function _(e,t={}){let{initialFocus:a,returnFocus:u=true,clickOutsideDeactivates:r=false,escapeDeactivates:n=true,onDeactivate:i,onEscapeFocus:c}=t,o=false,m=false,f=null;function h(l){m||!o||(l.key==="Tab"?y(l):l.key==="Escape"&&n&&(l.preventDefault(),l.stopPropagation(),v()));}function y(l){let E=T(e);if(E.length===0){l.preventDefault();return}let w=E[0],g=E[E.length-1],S=document.activeElement;l.shiftKey?(S===w||!e.contains(S))&&(l.preventDefault(),g.focus()):(S===g||!e.contains(S))&&(l.preventDefault(),w.focus());}function p(l){if(m||!o)return;let E=l.target;e.contains(E)||(c?.(E),A(e)?.focus());}function d(l){if(m||!o)return;let E=l.target;r&&!e.contains(E)&&v();}function b(){if(!o){f=document.activeElement,F.push(k);for(let l=0;l<F.length-1;l++)F[l].pause();document.addEventListener("keydown",h,true),document.addEventListener("focusin",p,true),document.addEventListener("click",d,true),o=true,requestAnimationFrame(()=>{if(!o)return;let l=q(a,e);if(l)l.focus();else {let E=A(e);E?E.focus():(e.setAttribute("tabindex","-1"),e.focus());}});}}function s(l){if(!o)return;document.removeEventListener("keydown",h,true),document.removeEventListener("focusin",p,true),document.removeEventListener("click",d,true),o=false,m=false;let E=F.indexOf(k);if(E>-1&&F.splice(E,1),F[F.length-1]?.unpause(),u&&f){let g=typeof u=="boolean"?f:u;requestAnimationFrame(()=>{g&&"focus"in g&&g.focus();});}l&&i?.();}function v(){s(true);}function L(){s(false);}function M(){!o||m||(m=true);}function H(){!o||!m||(m=false,P(e)||A(e)?.focus());}let k={activate:b,deactivate:v,destroy:L,pause:M,unpause:H,isActive:()=>o,isPaused:()=>m};return k}function z(){return F[F.length-1]??null}function W(){return F.length>0}var x={hadKeyboardEvent:true,isPointerInput:false,lastFocusSource:"unknown"},O=false,j=new Set(["Tab","ArrowUp","ArrowDown","ArrowLeft","ArrowRight","Enter"," ","Home","End","PageUp","PageDown","Escape"]);function G(){if(!chunk7BL2ABLF_cjs.a()||O)return ()=>{};O=true;function e(n){j.has(n.key)&&(x.hadKeyboardEvent=true,x.isPointerInput=false,x.lastFocusSource="keyboard");}function t(n){x.isPointerInput=true,x.hadKeyboardEvent=false,x.lastFocusSource="pointerType"in n&&n.pointerType==="touch"?"touch":"mouse";}function a(n){let i=n.target;i instanceof HTMLElement&&(x.hadKeyboardEvent||Y(i))&&(i.dataset.compa11yFocusVisible="true");}function u(n){let i=n.target;i instanceof HTMLElement&&delete i.dataset.compa11yFocusVisible;}function r(){document.visibilityState==="hidden"&&(x.hadKeyboardEvent=true);}return document.addEventListener("keydown",e,true),document.addEventListener("mousedown",t,true),document.addEventListener("pointerdown",t,true),document.addEventListener("focus",a,true),document.addEventListener("blur",u,true),document.addEventListener("visibilitychange",r,true),()=>{document.removeEventListener("keydown",e,true),document.removeEventListener("mousedown",t,true),document.removeEventListener("pointerdown",t,true),document.removeEventListener("focus",a,true),document.removeEventListener("blur",u,true),document.removeEventListener("visibilitychange",r,true),O=false;}}function Y(e){let t=e.tagName.toLowerCase(),a=e.getAttribute("type")?.toLowerCase();return !!(t==="input"&&(!a||a==="text"||a==="email"||a==="password"||a==="search"||a==="tel"||a==="url"||a==="number")||t==="textarea"||e.isContentEditable)}function J(){return x.hadKeyboardEvent}function Q(e){return e.dataset.compa11yFocusVisible==="true"}function X(){return x.lastFocusSource}function Z(e,t){t?e.dataset.compa11yFocusVisible="true":delete e.dataset.compa11yFocusVisible;}function $(e,t){x.hadKeyboardEvent=true,x.lastFocusSource="keyboard",e.focus(t);}function ee(e,t={}){let{contain:a=false,restoreFocus:u=false,autoFocus:r=false}=t,n=null,i=false;u&&(n=document.activeElement);function c(){return i?[]:T(e)}function o(){let s=document.activeElement;return s&&e.contains(s)?s:null}function m(){if(i)return;c()[0]?.focus();}function f(){if(i)return;let s=c();s[s.length-1]?.focus();}function h({wrap:s=true}={}){if(i)return;let v=o();if(!v){m();return}N(e,v,s)?.focus();}function y({wrap:s=true}={}){if(i)return;let v=o();if(!v){f();return}C(e,v,s)?.focus();}function p(s){if(i)return;c()[s]?.focus();}function d(s){if(!(i||!a)&&s.key==="Tab"){let v=c();if(v.length===0){s.preventDefault();return}let L=v[0],M=v[v.length-1],H=o();s.shiftKey&&H===L?(s.preventDefault(),M.focus()):!s.shiftKey&&H===M&&(s.preventDefault(),L.focus());}}function b(){i||(i=true,document.removeEventListener("keydown",d,true),u&&n&&n.focus());}return a&&document.addEventListener("keydown",d,true),r&&requestAnimationFrame(()=>{i||m();}),{focusFirst:m,focusLast:f,focusNext:h,focusPrevious:y,focusAt:p,getFocused:o,getElements:c,destroy:b}}function te(e,t,a={}){let{initialIndex:u=0,orientation:r="both",wrap:n=true,onSelectionChange:i}=a,c=[],o=u;function m(){c=Array.from(e.querySelectorAll(t)),c.forEach((p,d)=>{p.setAttribute("tabindex",d===o?"0":"-1");});}function f(p){if(c.length===0)return;let d=p;d<0?d=n?c.length-1:0:d>=c.length&&(d=n?0:c.length-1);let b=c[o],s=c[d];b&&b.setAttribute("tabindex","-1"),s&&(s.setAttribute("tabindex","0"),s.focus(),i?.(d,s)),o=d;}function h(p){let d=p.target;if(!c.includes(d))return;let b=false;switch(p.key){case "ArrowRight":(r==="horizontal"||r==="both")&&(f(o+1),b=true);break;case "ArrowLeft":(r==="horizontal"||r==="both")&&(f(o-1),b=true);break;case "ArrowDown":(r==="vertical"||r==="both")&&(f(o+1),b=true);break;case "ArrowUp":(r==="vertical"||r==="both")&&(f(o-1),b=true);break;case "Home":f(0),b=true;break;case "End":f(c.length-1),b=true;break}b&&(p.preventDefault(),p.stopPropagation());}function y(p){let d=p.target,b=c.indexOf(d);if(b!==-1&&b!==o){let s=c[o];s&&s.setAttribute("tabindex","-1"),d.setAttribute("tabindex","0"),o=b;}}return m(),e.addEventListener("keydown",h),e.addEventListener("focusin",y),{next:()=>f(o+1),previous:()=>f(o-1),first:()=>f(0),last:()=>f(c.length-1),goto:f,getIndex:()=>o,update:m,destroy:()=>{e.removeEventListener("keydown",h),e.removeEventListener("focusin",y);}}}function B(e,t={}){let{scope:a=e.parentElement??document.body,prefer:u="previous"}=t,r=T(a),n=r.indexOf(e);n===-1&&(n=r.findIndex(f=>e.compareDocumentPosition(f)&Node.DOCUMENT_POSITION_FOLLOWING),n===-1&&(n=r.length));let i=n-1,c=n+1,o=i>=0&&r[i]!==e?r[i]:null,m=c<r.length&&r[c]!==e?r[c]:null;return u==="previous"?o??m:m??o}function ne(e){let t=e??null;function a(n){t=n??document.activeElement??null;}function u(n={}){let{fallback:i,prefer:c="previous"}=n;if(!t){i?.focus();return}if(t.isConnected&&I(t)){t.focus(),t=null;return}if(t.isConnected){let o=B(t,{prefer:c});if(o){o.focus(),t=null;return}}i&&i.focus(),t=null;}function r(){t=null;}return {get element(){return t},save:a,return:u,clear:r}}exports.A=ne;exports.a=D;exports.b=K;exports.c=U;exports.d=V;exports.e=I;exports.f=oe;exports.g=T;exports.h=A;exports.i=re;exports.j=P;exports.k=N;exports.l=C;exports.m=ie;exports.n=q;exports.o=_;exports.p=z;exports.q=W;exports.r=G;exports.s=J;exports.t=Q;exports.u=X;exports.v=Z;exports.w=$;exports.x=ee;exports.y=te;exports.z=B;
@@ -1 +0,0 @@
1
- 'use strict';var chunk7BL2ABLF_cjs=require('./chunk-7BL2ABLF.cjs');var o=null,i=null,m=false,l=[],r=null;function L(){return {position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0"}}function x(n){let e=document.createElement("div");e.setAttribute("role","status"),e.setAttribute("aria-live",n),e.setAttribute("aria-atomic","true"),e.setAttribute("aria-relevant","additions text"),e.id=`compa11y-announcer-${n}`;let t=L();return Object.assign(e.style,t),document.body.appendChild(e),{element:e,politeness:n}}function b(){return !chunk7BL2ABLF_cjs.a()||m?()=>{}:(m=true,o=x("polite"),i=x("assertive"),()=>{o&&(o.element.remove(),o=null),i&&(i.element.remove(),i=null),r&&(clearTimeout(r),r=null),l=[],m=false;})}function R(){!m&&chunk7BL2ABLF_cjs.a()&&b();}function g(n){n.element.textContent="";}function a(n,e={}){if(!chunk7BL2ABLF_cjs.a())return;let{politeness:t="polite",delay:s=0,clearPrevious:c=false,timeout:A=7e3}=e;R();let u=t==="assertive"?i:o;if(!u)return;let d=()=>{c&&g(u),u.element.textContent="",requestAnimationFrame(()=>{u.element.textContent=n,A>0&&setTimeout(()=>{u.element.textContent===n&&(u.element.textContent="");},A);});};s>0?setTimeout(d,s):d();}function f(n,e){a(n,{...e,politeness:"polite"});}function v(n,e){a(n,{...e,politeness:"assertive"});}function O(){o&&g(o),i&&g(i);}function y(n,e={}){let{debounce:t=150,...s}=e;l.push({message:n,options:s}),r&&clearTimeout(r),r=setTimeout(()=>{let c=l[l.length-1];c&&a(c.message,c.options),l=[],r=null;},t);}function P(n={}){return {announce:(e,t)=>a(e,{...n,...t}),polite:(e,t)=>f(e,{...n,...t}),assertive:(e,t)=>v(e,{...n,...t}),queue:(e,t)=>y(e,{...n,...t}),clear:O}}function S(n){f(n);}function T(n){v(n);}function h(n,e,t="{current} of {total}"){let s=t.replace("{current}",String(n)).replace("{total}",String(e));f(s);}exports.a=b;exports.b=a;exports.c=f;exports.d=v;exports.e=O;exports.f=y;exports.g=P;exports.h=S;exports.i=T;exports.j=h;
@@ -1 +0,0 @@
1
- 'use strict';function f(e){let t=e.key;switch(t){case " ":return "Space";case "Esc":return "Escape";case "Left":return "ArrowLeft";case "Right":return "ArrowRight";case "Up":return "ArrowUp";case "Down":return "ArrowDown";default:return t}}function p(e){let t=[];e.ctrlKey&&t.push("Ctrl"),e.altKey&&t.push("Alt"),e.shiftKey&&t.push("Shift"),e.metaKey&&t.push("Meta");let d=f(e);return ["Control","Alt","Shift","Meta"].includes(d)||t.push(d),t.join("+")}function v(e={},t={}){let{preventDefault:d=true,stopPropagation:i=true,targetSelector:o}=t,n=new Map(Object.entries(e)),a=null;function l(r){if(o&&!r.target.matches(o))return;let y=p(r),c=n.get(y);if(!c){let u=f(r);c=n.get(u);}c&&c(r)!==false&&(d&&r.preventDefault(),i&&r.stopPropagation());}function g(r){a&&s(),a=r,r.addEventListener("keydown",l);}function s(){a&&(a.removeEventListener("keydown",l),a=null);}function h(r,y){n.set(r,y);}function m(r){n.delete(r);}function b(){s(),n.clear();}return {attach:g,detach:s,on:h,off:m,destroy:b}}var K={menu:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),Enter:()=>e.onEnter?.(),Space:()=>e.onEnter?.(),Escape:()=>e.onEscape?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),tabs:e=>({ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),dialog:e=>({Escape:()=>e.onEscape?.()}),grid:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.(),"Ctrl+Home":()=>e.onCtrlHome?.(),"Ctrl+End":()=>e.onCtrlEnd?.()})};function E(e,t={}){let{timeout:d=500}=t,i="",o=null;function n(){i="",o&&(clearTimeout(o),o=null);}function a(l){return l.length!==1||l===" "?null:(o&&clearTimeout(o),i+=l.toLowerCase(),o=setTimeout(n,d),e.find(s=>s.toLowerCase().startsWith(i))??null)}return {type:a,reset:n,getSearch:()=>i}}exports.a=f;exports.b=p;exports.c=v;exports.d=K;exports.e=E;
@@ -1 +0,0 @@
1
- function f(e){let t=e.key;switch(t){case " ":return "Space";case "Esc":return "Escape";case "Left":return "ArrowLeft";case "Right":return "ArrowRight";case "Up":return "ArrowUp";case "Down":return "ArrowDown";default:return t}}function p(e){let t=[];e.ctrlKey&&t.push("Ctrl"),e.altKey&&t.push("Alt"),e.shiftKey&&t.push("Shift"),e.metaKey&&t.push("Meta");let d=f(e);return ["Control","Alt","Shift","Meta"].includes(d)||t.push(d),t.join("+")}function v(e={},t={}){let{preventDefault:d=true,stopPropagation:i=true,targetSelector:o}=t,n=new Map(Object.entries(e)),a=null;function l(r){if(o&&!r.target.matches(o))return;let y=p(r),c=n.get(y);if(!c){let u=f(r);c=n.get(u);}c&&c(r)!==false&&(d&&r.preventDefault(),i&&r.stopPropagation());}function g(r){a&&s(),a=r,r.addEventListener("keydown",l);}function s(){a&&(a.removeEventListener("keydown",l),a=null);}function h(r,y){n.set(r,y);}function m(r){n.delete(r);}function b(){s(),n.clear();}return {attach:g,detach:s,on:h,off:m,destroy:b}}var K={menu:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),Enter:()=>e.onEnter?.(),Space:()=>e.onEnter?.(),Escape:()=>e.onEscape?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),tabs:e=>({ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.()}),dialog:e=>({Escape:()=>e.onEscape?.()}),grid:e=>({ArrowUp:()=>e.onUp?.(),ArrowDown:()=>e.onDown?.(),ArrowLeft:()=>e.onLeft?.(),ArrowRight:()=>e.onRight?.(),Home:()=>e.onHome?.(),End:()=>e.onEnd?.(),"Ctrl+Home":()=>e.onCtrlHome?.(),"Ctrl+End":()=>e.onCtrlEnd?.()})};function E(e,t={}){let{timeout:d=500}=t,i="",o=null;function n(){i="",o&&(clearTimeout(o),o=null);}function a(l){return l.length!==1||l===" "?null:(o&&clearTimeout(o),i+=l.toLowerCase(),o=setTimeout(n,d),e.find(s=>s.toLowerCase().startsWith(i))??null)}return {type:a,reset:n,getSearch:()=>i}}export{f as a,p as b,v as c,K as d,E as e};
@@ -1 +0,0 @@
1
- import {a as a$1}from'./chunk-C3VZQUKG.js';var o=null,i=null,m=false,l=[],r=null;function L(){return {position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",border:"0"}}function x(n){let e=document.createElement("div");e.setAttribute("role","status"),e.setAttribute("aria-live",n),e.setAttribute("aria-atomic","true"),e.setAttribute("aria-relevant","additions text"),e.id=`compa11y-announcer-${n}`;let t=L();return Object.assign(e.style,t),document.body.appendChild(e),{element:e,politeness:n}}function b(){return !a$1()||m?()=>{}:(m=true,o=x("polite"),i=x("assertive"),()=>{o&&(o.element.remove(),o=null),i&&(i.element.remove(),i=null),r&&(clearTimeout(r),r=null),l=[],m=false;})}function R(){!m&&a$1()&&b();}function g(n){n.element.textContent="";}function a(n,e={}){if(!a$1())return;let{politeness:t="polite",delay:s=0,clearPrevious:c=false,timeout:A=7e3}=e;R();let u=t==="assertive"?i:o;if(!u)return;let d=()=>{c&&g(u),u.element.textContent="",requestAnimationFrame(()=>{u.element.textContent=n,A>0&&setTimeout(()=>{u.element.textContent===n&&(u.element.textContent="");},A);});};s>0?setTimeout(d,s):d();}function f(n,e){a(n,{...e,politeness:"polite"});}function v(n,e){a(n,{...e,politeness:"assertive"});}function O(){o&&g(o),i&&g(i);}function y(n,e={}){let{debounce:t=150,...s}=e;l.push({message:n,options:s}),r&&clearTimeout(r),r=setTimeout(()=>{let c=l[l.length-1];c&&a(c.message,c.options),l=[],r=null;},t);}function P(n={}){return {announce:(e,t)=>a(e,{...n,...t}),polite:(e,t)=>f(e,{...n,...t}),assertive:(e,t)=>v(e,{...n,...t}),queue:(e,t)=>y(e,{...n,...t}),clear:O}}function S(n){f(n);}function T(n){v(n);}function h(n,e,t="{current} of {total}"){let s=t.replace("{current}",String(n)).replace("{total}",String(e));f(s);}export{b as a,a as b,f as c,v as d,O as e,y as f,P as g,S as h,T as i,h as j};